OT: About function IsPrinter( ) of Clipper

General Help regarding HMG, Compilation, Linking, Samples

Moderator: Rathinagiri

Post Reply
jparada
Posts: 430
Joined: Fri Jan 23, 2009 5:18 pm

OT: About function IsPrinter( ) of Clipper

Post by jparada »

To replace the function IsPrinter () of Clipper, and functioning properly test to check if the printer is online under Windows XP (And Windows Vista Also), can I use another function, (a trick, the third library, etc.).

Thanks

Greetings
Javier

Español,

Para sustituir la función IsPrinter( ) de Clipper, y que funcione correctamente el test para saber si la impresora esta en línea bajo Windows XP (y quizá también en Windows Vista), que otra función puedo utilizar, (algún truco, librería de terceros, etc.)

Gracias

Saludos
Javier
User avatar
sudip
Posts: 1454
Joined: Sat Mar 07, 2009 11:52 am
Location: Kolkata, WB, India

Re: OT: About function IsPrinter( ) of Clipper

Post by sudip »

Hi,

As per Harbour help,
ISPRINTER() is a printer function that determines whether the parallel port (LPT1) is online and ready to print. ISPRINTER() is hardware-dependent and, therefore, only works on IBM BIOS compatible systems.
You can check ISPRINTER() to make sure the printer is ready before you begin a print operation; however, if an error occurs during the print operation, a runtime error is generated.
But, if we are using Windows printing, OS will take the charge. In case there is a printing problem, it stores the printer queue to print it later.

Please teach me, if I am wrong. Because, I am very week in Windows programming.

With best regards.

Sudip
With best regards,
Sudip
jparada
Posts: 430
Joined: Fri Jan 23, 2009 5:18 pm

Re: OT: About function IsPrinter( ) of Clipper

Post by jparada »

Thanks for answering Sudip, but your response
As per Harbour help,

ISPRINTER() is a printer function that determines whether the parallel port (LPT1) is online and ready to print. ISPRINTER() is hardware-dependent and, therefore, only works on IBM BIOS compatible systems.
You can check ISPRINTER() to make sure the printer is ready before you begin a print operation; however, if an error occurs during the print operation, a runtime error is generated.


Is about Harbour, and I mean Clipper, I do not have time right now to trying to compile my old Clipper program to migrate to Harbour.

Thank you very much

Best regards
Javier
User avatar
sudip
Posts: 1454
Joined: Sat Mar 07, 2009 11:52 am
Location: Kolkata, WB, India

Re: OT: About function IsPrinter( ) of Clipper

Post by sudip »

Hi Javier,

I don't know any HMG function which tests if the printer is online or not :( But, I don't require it. Because OS itself takes the charge to test whether a printer is online or not :)
Javier wrote:Thanks for answering Sudip, but your response
...
...
Is about Harbour, and I mean Clipper, I do not have time right now to trying to compile my old Clipper program to migrate to Harbour.
My IsPrinter() function description is taken from Harbour Help file (I already told you).

AFIK, HMG is a GUI library for Microsoft Windows, running on Harbour, and so we can use all the Harbour functions with HMG (most probably you already knew it)

And I didn't tell you to compile your Clipper apps to migrate to Harbour.
Sudip wrote:But, if we are using Windows printing, OS will take the charge. In case there is a printing problem, it stores the printer queue to print it later.
AFIK, HMG uses HB_Printer (again please rectify me, if I am wrong). It is not restricted to LPT1. You may always use IsPrinter() with HMG but it may not be "very" useful.

BTW, do you want a function which will inform if printer is not working? Then do the same with any good windows application software. Power off your printer and try to print from that software. Does that program show you any error message. You will get the error message from OS itself. Same thing will happen with HMG generated apps also.

Regards.

Sudip
With best regards,
Sudip
jparada
Posts: 430
Joined: Fri Jan 23, 2009 5:18 pm

Re: OT: About function IsPrinter( ) of Clipper

Post by jparada »

Thanks for your answers Sudip,

Greetings
Javier
Post Reply