thenemesiz
asked on
WMI Pause, Resume & Cancel Printing in VB6
I would like to use VB6 to:
- Monitor default printer
- Pause any print job
- Run a sub
- If sub returns true then resume printing
- If not the cancel the print job
The default printer is a receipt printer that doesn't print any other documents.
I have successfully identified the default printer using WMI and can call the printer by a sub:
Dim objPrinter As Printer
Set objPrinter = GetDefaultPrinter()
MsgBox "Default printer is: " + objPrinter.DeviceName
MsgBox "Driver name is: " + objPrinter.DriverName
MsgBox "Port is: " + objPrinter.Port
Set objPrinter = Nothing
Can someone please help me pause any jobs on the printer till the above steps are followed
Thanks a Billion
- Monitor default printer
- Pause any print job
- Run a sub
- If sub returns true then resume printing
- If not the cancel the print job
The default printer is a receipt printer that doesn't print any other documents.
I have successfully identified the default printer using WMI and can call the printer by a sub:
Dim objPrinter As Printer
Set objPrinter = GetDefaultPrinter()
MsgBox "Default printer is: " + objPrinter.DeviceName
MsgBox "Driver name is: " + objPrinter.DriverName
MsgBox "Port is: " + objPrinter.Port
Set objPrinter = Nothing
Can someone please help me pause any jobs on the printer till the above steps are followed
Thanks a Billion
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
that's extremely helpful 'dax bad'
Appreciated!!
Appreciated!!
http://www.activxperts.com/activmonitor/windowsmanagement/adminscripts/printing/servers/#PausePrintJobs.htm
Open in new window