You could try something like the following in a button script. You could hide and overlay the standard quick print and print buttons with your fake button. The script will invoke the button you specify and after returning from the quick print or printing screen, the drawer should open if you've sent the right character string. I noticed the post is displaying the sPrinterName incorrectly so i attached the script as well. There should be 2 slashes before the server name.
_______________________________
Dim sPrinterName
Dim oFSO
Dim oPrinter
Dim sButtonToInvoke
Dim sCharacterStringToSend
sButtonToInvoke = ""BT_Print"" ' Use this to invoke the button with the printer icon. Comment out as needed.
sButtonToInvoke = ""BT_QuickPrint"" ' Use this to invoke the button for Quick Print. Comment out as needed.
sCharacterStringToSend = Chr(7) ' the 7 is the ASCII character for the BELL symbol which is used by some register printers to signal a connected drawer to open. Refer to printer's manufactuer documentation for the correct characters to send.
oScript.InvokeButton sButtonToInvoke
oUIObj.HandleScriptUI
sPrinterName = ""\\localhost\Send To OneNote 2010"" ' This must be a valid printer share name. If printing to a local printer, make sure the printer is shared. This can also print to a printer on a remote server, just replace localhost with the remote server name and make sure to use the share name of the printer.
Set oFSO = CreateObject(""Scripting.FileSystemObject"")
On Error Resume Next
Set oPrinter = oFSO.CreateTextFile(sPrinterName, False)
oPrinter.Write sCharacterStringToSend
oPrinter.Close
On Error GoTo 0
Set oPrinter = Nothing
Set oFSO = Nothing
_______________________________