Click here to Skip to main content
15,947,785 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
Hey there,

Recently I got an answer on how to send a data stream to the printer.

But the problem is I have a USB printer and data is going to the printer buffer but it is not getting printed.

Is it necessary to have a paraller port printer like the dot matrix printer or any settings to be made to the USB printer like HP deskjet 1400 series.
Posted
Updated 8-Dec-09 10:55am
v2

I recently encountered the same problem, i.e not able to give print to a usb printer. I solved by doing these steps :

* First go to 'C:\WINDOWS\system32\drivers\etc' in your system(xp) and there you will find '127.0.0.1 localhost'.
* Now instead of mapping your \\systemName\usbPrintersharename try this

In command window,
net use lpt1 \\127.0.0.1\usbprintersharename

for eg . net use lpt1 \\127.0.0.1\tvs where 'tvs' is the share name of my usbprinter.

Now ,try giving a print to the usb printer from code,it will work.
 
Share this answer
 
wrote:
Is it necessary to have a paraller port printer


No, a USB printer should work fine whatever you try to print to it. Check your printer settings, run a test page etc.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900