Navigation: ABC Library Reference > ErrorClass > ErrorClass Methods >====== RemoveError (remove an individual error) ====== | |
RemoveError( error ID )
RemoveError | Removes an error from the error entry queue specified by the error ID. |
error ID | A USHORT value (usually an EQUATE) that identifies the error message identifier stored in the ErrorClass Errors QUEUE |
RemoveError is used to remove a specific error entry stored in the QUEUE referenced by the Errors PRIVATE property. This queue is protected from direct access due to internal protection in a multi-threaded environment. RemoveError provides a thread safe access to this error entry queue.
Implementation:
RemoveError should be called after the Init method of the ErrorClass, and prior to the AddError method.
Example:
CODE
GlobalErrors.Init(GlobalErrorStatus)
INIMgr.Init('.\IMPeople.INI', NVD_INI) ! Configure INIManager to use INI file
DctInit
GlobalErrors.RemoveError(Msg:LogoutFailed)
MessStr = 'You are not allowed to delete this record'
MessTitle = 'Test Error'
MessCat = ''
GlobalErrors.AddError(Msg:LogoutFailed,MessStr,MessTitle,Level:Notify,MessCat)
See Also: AddError