XLL+ Class Library (6.3)

CXllApp::ErrorToStringA

Convert an error value to a string.

static const char* ErrorToStringA(
   unsigned short err
);

Parameters

err

An error value (e.g. xlerrValue).

Return Value

A pointer to a static string buffer containg the string value of the error, as it would be displayed in Excel, e.g.: #N/A!, #DIV/0! etc.

Remarks

Since this function is static, it is not necessary to use an instance of CXllApp to invoke it. It is not therefore necessary to fix the MFC CWinApp instance using the XLL_FIX_STATE macro: you can use code such as:

CString strResult = CXllApp::ErrorToString(xlerrValue);

Requirements

Header: xllplus.h

See Also

CXllApp Class | CXllApp Methods