LBase::SetErrorString

#include "ltwrappr.h"

static L_VOID LBase::SetErrorString (nErrorCode, pszNewErrString, pszOldErrString=NULL, uSizeOldErrStrBuff=0)

Changes the error string for one of the LEADTOOLS error codes.

Parameters

L_INT nErrorCode

One of the LEADTOOLS error codes.

L_TCHAR * pszNewErrString

Pointer to a buffer that contains the new error string for the specified error code. The string must not exceed 256 characters, including the terminating NULL. The contents of this buffer will be copied, and you should free this buffer when you are finished with it.

L_TCHAR * pszOldErrString

Pointer to an optional buffer that will be updated with the old error string for the specified error code. The string must not exceed 256 characters, including the terminating NULL. You must allocate the memory for this buffer and free it when you are finished with it.

L_UINT uSizeOldErrStrBuff

Size of the pszOldErrString passed buffer. This parameter is ignored if pszOldErrString is NULL.

Returns

None.

Comments

Call this function to change the error string for one of the LEADTOOLS error codes. This will change the internal error string for the specified error code. When displaying the string for this error code, the new string will be used.

Required DLLs and Libraries

Platforms

Win32, x64.

See Also

Example

L_INT LBase__SetErrorStringExample() 
{ 
	 
	LBase Base; 
	 
	Base.SetErrorString(WRPERR_BITMAP_NOT_ALLOCATED, TEXT("UserMessage - Bitmap not allocated.")); 
	Base.DisplayError(NULL, WRPERR_BITMAP_NOT_ALLOCATED); 
 
	return SUCCESS; 
} 
Help Version 21.0.2021.7.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C++ Class Library Help