PMSessionSetError(_:_:)
Sets the value of the current result code for the specified printing session.
Declaration
func PMSessionSetError(_ printSession: PMPrintSession, _ printError: OSStatus) -> OSStatusParameters
- printSession:
The printing session whose result code you want to set.
- printError:
The result code you want to set. This result code is returned by the
PMSessionErrorfunction.
Return Value
A result code. See Result Codes.
Discussion
You must call this function between the creation and release of a printing session. See the function PMCreateSession(_:).
You can use this function to terminate a printing session if your application encounters any errors inside the print loop. Typically, this function is used by an application’s idle function. The idle function isn’t called in macOS, so this usage is not available.