We recently installed Sage 300 2019 PU4 and discovered an issue where printing any report from a custom screen (OCX in an AVB Macro or VB Project) where Print Destination is set to Printer and Confirm on print is checked results in a crash i.e.
Print Destination > Printer
View > Print Preferences > Confirm on print > Checked
The issue seems to boil down to the custom screen crashing when the print button is clicked i.e.
Instead of showing the following screen (as per non-custom Sage screens)…
… the following error is displayed, and the custom screen crashes:
Only custom screens seem to be affected.
A workaround is to ensure the Confirm on print checkbox remains un-checked, to avoid the Print dialogue loading and crashing the program.
This can be reproduced by:
- Adding a form to an empty macro
- Adding an OCX e.g. OE1100) to the form
- Running the macro
- Setting Print Destination to Printer
- Setting Confirm on print to checked
- Setting a default physical printer (in Windows) i.e. not XPS etc.
- Posting an Order
- Clicking the print button
We’re wondering if this issue is related to the report printing fix in Sage 300 2019 PU4. If that’s the case, then a similar fix made its way into Sage 300 2018 PU7, and possibly other updates/releases, which may also be affected.