Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Clipper and USB port 1

Status
Not open for further replies.

bismir

Programmer
May 14, 2001
23
BA
I try to print reports from my clipper APPS to USB printer but there is no chance.
I use Win98 and have installed printer to USB port.

Any with idea how to resolve this problem ?

If I put computer in network I can share printer and from another computer redirect printer to Lpt1 but I can not redirect printer on same computer where printer is installed.

Thank you !
 
Hello,

Just print to a file and use "\\computer\printershare" as the filename. Maybe you'll have to catch errors for the file being non-readable, but just ignore that error (I cought it in errorsys, see lower) and keep on writing. This also works nicely for other non-mapped (LPT?) printers in the network, only you can't browse for a port (that I know of), you'll have to enter the name by hand, or read from a config file.

Btw, the code I added to errorsys is this:

If e:genCode == EG_OPEN ;
.and. e:canDefault ;
.and. e:eek:sCode == 32 // Sharing Violation error
/* driver default */
NetErr(.t.) // Return Network Open-error
Return(.f.) // Resume Open command /* NOTE */
Endif

HTH
TonHu
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top