When printing a graph, user receives an error message:
Error printername - GSOpenPrn returned -1
User gets no output. There is a known 32-character printer name and path limitation with GSOpenPrn from Graphics Server (the OCX WIMS uses for graphing).
Solution 1: In version 7.2.2 and later, you may want to try Print Graph Method 1 for output of graphs. See Print Graph Method General Setting.
Solution 2: The user has to shorten the printer name. Go to Control Panel, Printers and rename the printer.
The following are the Tech Notes from Graphics Server:
The call to GSOpenPrn("", "", style) is returning a failure (-1).
There is a known 32-character printer name and path limitation with GSOpenPrn.
This is due to an internal usage of a 16-bit API that has a 32-character bottleneck at the printer name/path. You can check to see if this is the case by looking at your default printer and counting chars.
This failure usually only happens in networked printer environments, and in situations where names and paths are unnecessarily long.
Solutions? Not many. Aside form renaming the printer and possibly it's path/server, there are no alternatives while still sticking with GSOpenPrn and the GS printing APIs.
For Citrix/TerminalServices, see HOWTO: Shorten autogenerated printer names (that are too long) in Citrix / Terminal Services