Invoking Web Services Asynchronously
One of the benefits of the multithreading model in Visual Basic .NET is the asynchronous invocation capabilities built on top of the threading model. (Refer to Chapter 6 for more information.) Asynchronous behavior is an integral part of .NET, and this capability is extended to XML Web Services. Following the basic concept of asynchronous behavior from Chapter 6, you can use exactly the same technique to invoke a Web Service asynchronously.
The WSDL utility always adds the asynchronous Beginname and Endname methods in the proxy class for each Web method (where name is the name of the Web method). Thus, if you want to invoke a Web method asynchronously, all you need to do is define a callback method, pass this ...
Get Visual Basic® .NET Power Coding now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.