While setting up a new Windows 7 computer for a customer, the user had several programs that were very old. There was one program in particular that was written in the 1980s and was a DOS based program. This was a program that was custom written for this company to calculate the dividends for their partners, so no upgrade existed nor did they want to use another process. The program was very simple, click the appropriate DOS program and the report and checks print.
I found that the ports in the printer properties GUI do not correspond to the DOS printers. To print to a printer using DOS, you must use the following command to map the printer: net use port \\server\printer. You can run net use from a command prompt to see what devices are connected via command line. [more]
As you can see in the screenshot below, Printer1 is mapped to LPT2 from the GUI and LPT1 from the command line.
The solution for adding the printer so the DOS program could print was to place a batch file in the startup folder with the net use port \\server\printer command so the printer will be mapped each time the computer starts. This resolve this issue and allowed the DOS program to print to the printer on the new Windows 7 PC.