LPRINT COMMAND UNDER WINDOWS XP

If you have questions about any aspect of QBasic programming, or would like to help fellow programmers solve their problems, check out this board!

Moderators: Pete, Mods

Post Reply
peter
Newbie
Posts: 1
Joined: Sun Jan 16, 2005 4:11 pm

LPRINT COMMAND UNDER WINDOWS XP

Post by peter »

LPRINT does not function when running QBASIC in XP environment .
Any help on this ?
Thanks
User avatar
Pete
Site Admin
Posts: 887
Joined: Sun Dec 07, 2003 9:10 pm
Location: Candor, NY
Contact:

Post by Pete »

LPRINT uses the parallel port interface (LTTP), and most printers that are sold these days use the USB port. If you're using a USB printer, you're out of luck. Try a parallel port printer if you have one, but I can't make any guarantees.

It also could be a DOS compatibility error with Windows XP. Windows XP is no longer fully DOS compatible, so the XP "Command Prompt" might be having trouble interfacing with parallel port on your computer. I'm sure there are very technical ways to get around this, but I'm not the right person to ask.

Good luck!
MystikShadows
Veteran
Posts: 703
Joined: Sun Nov 14, 2004 7:36 am
Contact:

Post by MystikShadows »

You might be able to make it work if you take out Print Spooling on the printer port it's on.....Also They sell USB to Parallel port connectors, you might be able to make it work this way.
When God created light, so too was born, the first Shadow!

MystikShadows

Need hosting? http://www.jc-hosting.net

Interested in Text & ASCII development? Look no further!
http://www.ascii-world.com
User avatar
{Nathan}
Veteran
Posts: 1169
Joined: Thu Aug 19, 2004 6:08 pm
Location: The wetlands of central Ohio, USA
Contact:

Post by {Nathan} »

I had this same problem :roll: The solution is very easy :D

1. Find your printer drivers (anywhere, check Windows Update)
2. Uninstall your current ones. :P
3. Reinstall, but make sure you configure it for DOS. It will probably ask you :o

And your done... (or are you :twisted: )?

The end...

? :evil:
Image
Z!re
Veteran
Posts: 887
Joined: Wed Aug 04, 2004 11:15 am

Post by Z!re »

Not all printers have drivers for DOS, infact, very few modernprinters do.

Mine doesent have drivers for anything earlier than windows 98SE, for example.
I have left this dump.
User avatar
UWLabs
Coder
Posts: 12
Joined: Sun Oct 03, 2004 7:53 am
Location: Tennessee

LPRINT issues.

Post by UWLabs »

Since most new printers are now USB only your choice like the others have said are limited. One choice of course would be to hook up and OLD printer port printer. (LPT1) - Obvious and well, then you need another printer.

A "work-around" is too "print" to a text file.
You can even force the text file to appear in Notepad afterwards, and optionally print from there.

Like this (after you make the file):

SHELL "notepad.exe c:\myfile.txt /p"

The only drawback is the user is left at notepad and has to close it and then click on the minimized program.

Hope this helps.
Post Reply