Method HasResponse
Checks if methos has a ready responseUsage
Function HasResponse()
Parameters
This method does not take parameters
Returns
True if response is not null
Example
VBScript
' Execute method if doesn't have response and get string response
If NOT Server("API Server").Method("GetBookById").HasResponse() Then
Server("API Server").Method("GetBookById").Execute
End If
msgbox Server("API Server").Method("GetBookById").GetStringResponse()
JavaScript
// Execute method if doesn't have response and get string response
if (!Server("API Server").Method("GetBookById").HasResponse()) {
Server("API Server").Method("GetBookById").Execute();
}
alert(Server("API Server").Method("GetBookById").GetStringResponse());