Return Parameters

The Connect Presentation Space function sets the return code to indicate the status of the attempt and, if successful, the status of the host presentation space.

Return Code Explanation
0 The Connect Presentation Space function was successful; the host presentation space is unlocked and ready for input.
1 An incorrect host presentation space ID was specified. The specified session either does not exist or is a logical printer session. This return code could also mean that the API Setting for EHLLAPI is not set on.
4 Successful connection was achieved, but the host presentation space is busy.
5 Successful connection was achieved, but the host presentation space is locked (input inhibited).
9 A system error was encountered.
11 This resource is unavailable. The host presentation space is already being used by another system function.