Remote Printing from a DOS Program
Question:Is there a way to print to a network printer on a Windows NT/2000 PC, from a DOS Window (that defaults to printing to lpt1).
William Nester
Answer:To do this you need to reassign an LPT to the remote printer from within a Command Line Window on the computer where you are running the DOS program. You need to select an LPT address that is not already assigned. Assuming that you don't have LPT1 assigned already to a local printer you can use that otherwise use LPT2.
To actually redirect the appropriate LPT to the remote printer you use the NET command. The format of the command is:
NET USE LPTn: \\computername\remoteprinter
Just substitute the appropriate LPT number that you decide to use, the name of the remote computer, and the name of the remote printer on that computer. All that remains to be done then is to configure the DOS program to use the appropriate LPT address (if it doesn't already).


