General information
Title:
How to set the default printer?
Hello everyone:
Could you gave me some advice on how to set the default printer? I want to using the following code but it didn't work, it return cann't found the dll entrance. Thank you.
LOCAL lcOldPrinter AS String, ;
lcNewPrinter AS String
lcOldPrinter = SET("Printer", 2)
lcNewPrinter = GETPRINTER()
IF NOT EMPTY(lcNewPrinter)
SET PRINTER TO NAME (lcNewPrinter)
ENDIF
* Declare the API call, NOTICE the specific name
* for the DLL here!
DECLARE Integer SetdefaultPrinter IN ;
WINSPOOL.DRV String
* Set the printer
SetDefaultPrinter( (lcNewPrinter) )
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only