November 2003
Intermediate to advanced
476 pages
14h 38m
English
Of course, you shouldn’t
have to build HTTP or SOAP requests by hand. And indeed, you
don’t; the .NET Framework SDK includes a tool,
wsdl.exe, which can generate web service client
code from any WSDL file.
Run the command line wsdl /language:vb
http://127.0.0.1/dotNetAndXml/InventoryQuery.asmx?WSDL to
produce the Visual Basic .NET source code listed in Example 10-7 for the InventoryQuery
service.
'------------------------------------------------------------------------------ ' <autogenerated> ' This code was generated by a tool. ' Runtime Version: 1.0.3705.288 ' ' Changes to this file may cause incorrect behavior and will be lost if ' the code is regenerated. ' </autogenerated> '------------------------------------------------------------------------------ Option Strict Off Option Explicit On Imports System Imports System.ComponentModel Imports System.Diagnostics Imports System.Web.Services Imports System.Web.Services.Protocols Imports System.Xml.Serialization ' 'This source code was auto-generated by wsdl, Version=1.0.3705.288. ' '<remarks/> <System.Diagnostics.DebuggerStepThroughAttribute( ), _ System.ComponentModel.DesignerCategoryAttribute("code"), _ System.Web.Services.WebServiceBindingAttribute(Name:="InventoryQuerySoap", [Namespace]:="http://angushardware.com/InventoryQuery")> _ Public Class InventoryQuery Inherits System.Web.Services.Protocols.SoapHttpClientProtocol '<remarks/> ...