Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Issue relating to net use command on Windows NT

Status
Not open for further replies.

TomKane

Programmer
Jul 24, 2001
1,018
AU
Hello,

We have an issue relating to 'net use' on Windows NT ver 4, SP 4 and would be grateful for any advice you may have on the matter.

We have a DOS application that has a particular program that automatically prints a report straight to the printer without the option of saving to a file.

We know that we can set up a dummy printer in the control panel and then do a net use command so that the report is captured to a file, the command we use is as follows :

NET USE LPT1: /DELETE
NET USE LPT1: \\computername\generict

It works OK on my computer as my computer name is 10 characters. The computer on which this solution is intended for is about 16 characters in length - so we get the following error :

System error 67 has occurred.

The network name cannot be found.

The computer name can not be shortened due to a standard naming convention within the company.

Does anyone have any ideas?

Thanks.

 
Unfortunately net use will only work for a computername of 1 to 15 characters. If you want to use it you'll have to shorten the name. Sorry.
John
 
Try replacing servername with the IP address in the net use command.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top