I have a client that I have to capture a printer port for but all of a sudden I can capturer the port but I am not able to print to the device after I capture the LPT1 port. Any ideas would be great.
From your post, I would assume you are using the net use command to redirect a local printer port (LPT1) to a networked printer (\\print_server\printer). I would also assume that when you issue the "NET USE LPT1: \\print_server\printer" you receive a message indicating that the command worked.
Are you using any other options with the NET USE -- /PERSISTENT, user and/or password, etc?
If you type "NET USE" in a command window and press enter is the redirected printer listed, and if so what is the status.
Most importantly, can you print a test page to the network printer throught the normal windows process?
It tells me that it is mapped to the printer but I and I can print a test page through windows. I am not sure what to think of this issue. One thing though I am just using the NET USE LPT1: \\print_server\printer so should I be using the /persistent?
The /persistent option causes the share to reconnect when the machine is rebooted (in theory). It is not as reliable as it should be, so if you have something setup to add the share when needed, I would leave it in place.
The fact that you can print to the printer through Windows pretty much (although not totally) rules out driver problems.
The next step would be to try to print from a command prompt. Open a command prompt. Type 'cd %windir%\system32' and press enter. Make sure the printer is ready to go and type 'dir > LPT1:' This should send a directory listing to the printer in question.
Some printers may not eject the last page as this is just plain text and does not have a final form feed. Some may not print anything at all, but you should see some indication that the printer has data. Usually a press of the form feed button will get it moving.
You may receive an error message. Please report.
If this does not work, the next step would be to try your net use command with LPT3: and try the 'dir > LPT3:'. This exercise will determine if you are having a spooler problem or a problem with your application. Using a different port (LPT3) eliminates conflicts with the physical LPT1: port.
Also, it may become helpful to know what kind of printer you are dealing with.
One thing that is very important under XP is to realize that the LPT1 port is somewhat sacred. Only Administrators are allowed a Net Use of LPT1 without relying on DEVCON.EXE first:
So if you are scripting or using a CMD file in say the logon script to do a net use statement for LPT1, it is going to fail without DEVCON.EXE or oddly, using Device Manager to disable LPT1 in your default hardware profile.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.