Dear Greeny:

In your command file, create a variable like:

SET VAR gPrinter TEXT = NULL
SET VAR gPrinter = (CVAL('Printers'))

(CVAL('Printers')) returns the current windows default printer.   If it is
NULL then the user doesn't have a default windows printer installed.  In
your printing block of code, you could do something like this:

IF gPrinter IS NULL THEN
  PAUSE 2 USING 'No printer installed ... Report will not print.' +
    CAPTION 'Warning' AT CENTER CENTER
ELSE
  OUTPUT PRINTER
  PRINT reportname ...
  OUTPUT SCREEN
ENDIF

-----------------------------------------------------------
Sami Aaron
Software Management Specialists
19312 W 63rd Terr
Shawnee KS  66218
913-915-1971
http://www.softwaremgmt.com

----- Original Message -----
From: rbase rbae
To: rbti 2002
Sent: Tuesday, November 12, 2002 5:36 AM
Subject: printer driver detection


Greeny question,
What documentation or which website, or any input on how to
detect a printer driver from a  computer using rbase ?
I have a snipet of rbase code that prints the report but
when a computer that doesn't have any "printer driver installed"
run the instance of print snipet it will cause the rbase to abort
and generate error, I like to insert a code to detect printer driver
 if any and proceed or display appropriate "screen message".
Will this be effective approach or is there any better solution?
I'm using RB65++ win. vers
Thankx  for any comments.




Do you Yahoo!?
U2 on LAUNCH - Exclusive medley & videos from Greatest Hits CD


================================================
TO SEE MESSAGE POSTING GUIDELINES:
Send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: INTRO rbase-l
================================================
TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: UNSUBSCRIBE rbase-l
================================================
TO SEARCH ARCHIVES:
http://www.mail-archive.com/rbase-l%40sonetmail.com/

Reply via email to