|
November 22, 2001 Handling the result Object Tips: November 2001
Yehuda Shiran, Ph.D.
|
|
One of the two ways to call a Web service is with a callback handler. Here is an example that calls the add method with two arguments, intA and intB:
The event handler mathResults() accepts the result object as its sole parameter:
The name of the parameter can be different than "result". Inside, it checks whether there were errors during the call to the Web service:
Use this check to write an event handler that processes the result object and prints the error details (if any) as well as the result value. Here is a Microsoft example:
People who read this tip also read these tips: Look for similar tips by subject: |