This documentation was styled with a demo skin from the Premium Pack 4 add-on for Help & Manual. The contents of the skin are encrypted and not configurable. You can only publish HM projects with this skin. You cannot edit it or change it.
This version is copyright and may only be used for local testing purposes. It may not be distributed.
Please purchase the full version of the Premium Pack to get the configurable skins and remove this notice. The package will also include the Toolbox configuration utility for Premium Pack skins.
Description
Allows the requesting server to suspend execution while waiting for an asynchronous send operation to complete.
Syntax
n = <cHTTP_Client>.WaitForResponse(nSecs)
Returns
Number.
Parameters
Name |
Type |
Optional |
Meaning |
nSecs |
Number |
No |
Specifies the number of seconds to wait for an asynchronous send operation to complete. |
Remarks
The waitForResponse method is more efficient than polling the readyState property, which is the only way to wait for an asynchronous send using the cHTTP_Client component.
The method returns %True if a response is received within the time allotted, or %False if a timeout occurs.
If the method times out, the request is not aborted; the caller can continue to wait for the request in a subsequent call to the waitForResponse method. Calling waitForResponse after a synchronous send method returns immediately and has no useful effect.
The async parameter to the open method controls whether the send is synchronous (default) or asynchronous.
The results of this method are valid only after the send method has been completed successfully.
Restrictions
See also
Examples