用wsdl命令生成Web Service的客户端代码文件
wsdl.exe /l:cs /n:myNamespace /out:myFilename.cs http://www.abc.com/hello/hello.asmx?wsdl
将生成的文件如myFilename.cs,通过CSC或者VBC编译工具,生成相应的Proxy Dll文件即可如:
csc /target:library /out:"c:\proxy.dll" c:\proxy.cs
wsdl /l:cs /n:BbsInterface /out:ForPngWebService.cs http://10.0.0.1/ForPngWebService.asmx?wsdl
csc /target:library /out:"ForPngWebServiceProxy.dll" D:\WebSite\ForPngWebService.cs