MSI Factory 2.3

HTTP.GetHTTPErrorInfo

HTTP.GetHTTPErrorInfo

This is the first topic This is the last topic  

HTTP.GetHTTPErrorInfo

This is the first topic This is the last topic  

OverviewExamples

table HTTP.GetHTTPErrorInfo (

)

Example 1

ErrInfo = HTTP.GetHTTPErrorInfo();

Gets the last HTTP error info and stores it in table ErrInfo.

Example 2

HTTP.Download("http://www.asitehere.com/file.ext", "c:\\file.ext",MODE_BINARY, 20, 80, nil, nil, nil);

 

if (Application.GetLastError() ~= 0) then

 

   local http_error = HTTP.GetHTTPErrorInfo();

   local error_text = http_error.Message .. "\r\nServer Status: " .. http_error.Status;

 

   Dialog.Message("HTTP Error: " .. http_error.Number, error_text, MB_OK, MB_ICONEXCLAMATION);

end

Downloads a file. If an error occurs, displays the extended HTTP error information.

See also: Related Actions


Learn More: Indigo Rose Software - MSI Factory - Buy Now - Contact Us