CustomProcess_GetLastError Function

Applies To: Implementing a custom process

Returns the  last error message from the DLL, usually after one of the other functions fails.


  CustomProcess_API BOOL __stdcall CustomProcess_GetLastError(void* clientHandle,

                                                              char* errorString);


[in] clientHandle

Unique ID used to identify the caller.

[in, out] errorString

String with the reason for the last failure.

Return Value

A Boolean value signifying if the error message was returned correctly.

Reporting errors and warnings: Any errors can be obtained by calling the GetLastError function which will give out the error message for the last error in the DLL.


The following example represents a partial C++ implementation of this function:


CustomProcess_API BOOL __stdcall CustomProcess_GetLastError(

    void* clientHandle, char* errorString)


    ClientHandle* myClientHandle = (ClientHandle*)clientHandle;

    strcpy(errorString, myClientHandle->errorString);

    return TRUE;


For a detailed example on how to implement this function, see Sample custom process.

Related Topics

See also: CustomProcess_Create, CustomProcess_SetWindow, CustomProcess_Initialize, CustomProcess_GetRow, CustomProcess_GetMetadata, CustomProcess_Cleanup, CustomProcess_SetCallbackFunctions, CustomProcess_SetAreaOfInterest, CustomProcessUI_Init, CustomProcessUI_ShowModalDialog, CustomProcessUI_GetUpdatedXML, CustomProcessUI_GetStatus, CustomProcessUI_GetProperty, CustomProcessUI_SetProperty, CustomProcessUIForm_GetUpdatedXML, CustomProcessUIForm_Init