I have a push button on a form that creates a query and calls a report
that needs to print to a label printer. I need to modify the Printer
Properties to change paper size and orientation. I have found that
sendkeys is the only way to effectively to do this. When I run the
form and push the button the code stops when I call:
Any code after that does not execute until I close the Print Menu. How
can I send sendkeys() to the Print Menu?
Any help would GREATLY be appreciated.
if NOT rHandle.open(strReportName) then
msgStop("Error opening " + strReportName, "Please make sure the report
exists and try again.")
else msgstop ("No Data" , "There are no labels to print for account.")
sendkeys ("%(O)") ;Go to Properties
sendkeys ("%(D)") ;Change to Default paper size
sendkeys ("%(L)") ;Change to Landscape orientation
sendkeys ("%(A)") ;Apply