I have a button script on Shipping data entry to export a text file, which works fine. v2015 Premium, server side button script.
The process is to click my button, then the user clicks Accept which starts packing slip printing. Now, the customer wants my button to Accept after the file export, and start the packing slip printing automatically... but the following code only saves the shipment. The Packing Slip Printing dialog does not show up.
retVal = oScript.InvokeButton(""BT_ACCEPT"")
Any ideas?
I tried adding this after the invoke command, but nothing changed.
retVal = oUIObj.HandleScriptUI()
I could probably switch to invoking the quick print button but I am curious why invoking BT_ACCEPT doesn't work the same way as actually clicking on it.