: Is this "Select Printer" message displayed by your program? : Does your program display the same message when you run it manually? : Do you use PrinterSetDefault method in 24x7? The select printer message only comes up when I'm scheduling the script file I created in 24x7. The script routine only calls another executable created from VB and prints the output that I'm setting the printer to. If I just launch the executable, the report prints directly to my default printer. Example: // This is a test to run lab reports and print to usergroup. Dim (default_prntr, String) Dim (process, Number) // Remember name of the default printer PrinterGetDefault default_prntr // Change default printer to PR3016 on PSHORF02 PrinterSetDefault "\\PSHORF02\PR3016,winspool,Ne08:" // Print daily status report using PR3016 RunAndWait("v:\Groups\Aspentech\Install\PrntTest.exe", "v:\Groups\Aspentech\Install",2000,process) // Change default printer to PR3024 on PSHORF02 PrinterSetDefault "\\PSHORF02\PR3024,winspool,Ne09:" // Print daily status report using PR3024 Run("v:\Groups\Aspentech\Install\PrntTest.exe", "v:\Groups\Aspentech\Install",process) // Restore default printer as it was before PrinterSetDefault default_printer -------------------- The executable has a print command that just prints to default printer.
|