Prints the content of the current window.
GSErrCode ACAPI_Automate ( APIDo_PrintID, API_PrintPars* printPars );
- [in] Control parameters; optional, if missing, the current defaults will be used
- The function has completed with success.
- The function is called from notification level
- No open project
printParscontains invalid data
For other common API errors see the API Errors document.
This function is used to print the content of the current window. This function performs a Print command in the server application.
To get more details on the parametrization refer to the API_PrintPars structure.
It cannot be called from notification level; the command is refused if other addons are running. Calling this function may notify other addons about the event. The caller addon does not get any notification. See the Notification Manager for further details.
This function performs complete operations, so it cannot be called neither during undoable operations nor during non-undoable commands. See more details on this topic at Command Overview.
API_PrintPars printPars; BNZeroMemory (&printPars, sizeof (API_PrintPars)); printPars.grid = true; printPars.printArea = PrintArea_CurrentView; printPars.fixText = false; printPars.scale = 20; GSErrCode err = ACAPI_Automate (APIDo_PrintID, &printPars, nullptr); if (err == NoError) ACAPI_WriteReport ("APIDo_PrintID ...OK", true);
- Version: API 2.1 or later
- Header: APIdefs_Automate.h