Having problems with your account or logging in?
A lot of changes are happening in the community right now. Some may affect you. READ MORE HERE

Handle multi status custom HTTP error messages such as HTTP: 4 - The server returned a Client Error Status code (4xx) - "423 Locked"?

Handle multi status custom HTTP error messages such as HTTP: 4 - The server returned a Client Error Status code (4xx) - "423 Locked"?

These types of messages can be handled using an Event Handler in Silk Performer e.g.:

dclevent
handler ErrorHandler
var
nError: number;
sAddInformation : string;
nCustomSeverity: number;
begin
nError := GetLastError(nCustomSeverity, null, null, sAddInformation );
if GetErrorCode(nError) = 4 then
if Strncmp(sAddInformation, "\"499", 4) = 0 then
RaiseError(CUSTOM_ERROR, "status code 499", SEVERITY_WARNING);
elseif Strncmp(sAddInformation, "\"416", 4) = 0 then
RaiseError(CUSTOM_MESSAGE, "status code 416");
end;
end;
end ErrorHandler;

Additional information on Event handlers and how to use them can be found in the 'Event Handler' section of Silk Performer Help.

DISCLAIMER:

Some content on Community Tips & Information pages is not officially supported by Micro Focus. Please refer to our Terms of Use for more detail.
Top Contributors
Version history
Revision #:
1 of 1
Last update:
‎2013-02-15 18:47
Updated by:
 
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.