edmiDefineErrorCode
EdmiError edmiDefineErrorCode(EdmiError errorCode, SdaiString errorText, SdaiOptions options);
Adds a user defined error code to the list of EDMinterface error codes.
Arguments
Type | Name | Comment |
EdmiError | errorCode | The new EDMinterface error code to define. Error codes shall be within the range limited by the symbols FIRST_USER_DEFINED_ERROR_CODE and LAST_USER_DEFINED_ERROR_CODE |
SdaiString | errorText | An error message that corresponds to the given EDMinterface error code |
SdaiOptions | options | Specifies the current options. The <options> value should be defined as a bitwise OR between the options to enable. All the option names are defined in the header file sdai.h . Default options are enabled when the value of <options> is set to zero. |
Return Value
Error rendering macro 'excerpt-include' : User 'null' does not have permission to view the page 'US:_r_EDMInterface'.
Options
Option | Comment |
REPLACE_EXISTING |
|
DELETE_EXISTING |
|
Example
#define XC_UNCOMPLETE = (FIRST_USER_DEFINED_ERROR_CODE + 0) #define XC_MISSING = (FIRST_USER_DEFINED_ERROR_CODE + 1) #define XC_ACCEPTED = (FIRST_USER_DEFINED_ERROR_CODE + 2) . . . edmiDefineErrorCode(XC_UNCOMPLETE, "XC-Uncompletely Populated", REPLACE_EXISTING); edmiDefineErrorCode(XC_MISSING, "XC-Population Missing", REPLACE_EXISTING); edmiDefineErrorCode(XC_ACCEPTED, "XC-Population Ok", REPLACE_EXISTING); . . . EdmiError rstat, userStatus; SdaiModel xc49Id; SdaiInteger nErr, nWrn; . . . if (rstat = edmiConvertModelsBN("xc_repository.xc32", "xc32_to xc49", "xc_repository.xc49", NULL, NULL, NULL, 0, NULL, 0, &xc49Id, &userStatus, &nWrn, &nErr)) { goto error; } else { if (userStatus != XC_ACCEPTED) { printf("\nError in : xc32_to xc49 mapping - %s\n", edmiGetErrorText(userStatus)); goto error; } } ... edmiDefineErrorCode(dllMissingErr, dllMissingMsg, REPLACE_EXISTING);
See also
Filter by label
There are no items with the selected labels at this time.