PBORCA_SessionGetError
Description
Gets the current error for an ORCA session.
Syntax
|
1 |
void PBORCA_SessionGetError ( HPBORCA hORCASession, LPTSTR lpszErrorBuffer, INT iErrorBufferSize ); |
|
Argument |
Description |
|---|---|
|
hORCASession |
Handle to previously established ORCA |
|
lpszErrorBuffer |
Pointer to a buffer in which ORCA will put the |
|
iErrorBufferSize |
Size of the buffer pointed to by lpszErrorBuffer. The |
Return value
None.
Usage
You can call PBORCA_SessionGetError anytime another ORCA function
call results in an error. When an error occurs, functions always return
some useful error code. The complete list of codes is shown in ORCA return codes. However,
you can get ORCA’s complete error message by calling PBORCA_SessionGetError.
If there is no current error, the function puts an empty string (“”)
into the error buffer.
Examples
This example stores the current error message in the string buffer
pointed to by lpszErrorMessage. The size of the buffer was set previously
and stored in dwErrorBufferLen:
|
1 2 3 |
PBORCA_SessionGetError(lpORCA_Info->hORCASession, lpORCA_Info->lpszErrorMessage, (int) lpORCA_Info->dwErrorBufferLen); |
In these examples, session information is saved in the data
structure ORCA_Info, shown in About the examples.