Step by step to start Web service (under) (below)

zhaozj2021-02-17  65

Join the previous one

4. Then some like Java is also like VB, it is easy to understand, that is, you have to generate an agent class, and then call the method in this class in the client, that is, Services. At this point, you need to use another tool in the Framework SDK to generate a .cs .cs .vb or .js file, compile this file to generate a DLL, is the so-called proxy class. Then you can complete all in the DOTNET web page, GUI form, web form, or console program. Specific statement:

WSDL /OUT :::mewebservice1.cs http://localhost/webservice1/service1.asmx

You can see this CS file generation after success.

5. Then compile this class

CSC /OUT: MyWebService1.dll / T: library /r:system.xml.dll /r:System.Web.Services.dll mywebservice1.cs

If the success of the DLL is also generated, it is now called this service to write a session. I hand in this manual way, I think it is what I generated. WSDL is not used, that is, I can't find this Services.

4, 5 I am hand-made, don't want to build a project to compile myWebService1.cs. There is a benefit of the DOTNET, and the components are only automatically registered with compile. They don't need to regr32 like COM, and the current COM components and DOTNET components are completely different, that is, in the VB's Reference and OleView you will be disappointed. This DOTNET component is not available.

6. Then you can call this component in your application, the app is simple, and the general is:

DIM OBJ AS New Service1

DIM RETSTR AS STRING

Dim Retintval As String

Retstr = Obj.helloworld ()

Retintval = Obj.Add (300, 500)

It seems that DOTNET is still very interesting, at least show you a different thing, I want to use COM or COM heroes to easily think of this similar to a remote or internet method, the previous COM is fatal Weakness, unable to penetrate the firewall, now this method is not only flexible and the agreement is more standard. The bottom layer is packaged and hidden from SOAP and other network protocols, and the intermediate is transmitted by XML to deliver data and information. You only use concentrations on the service.

Think about Sina's news service If there is such a web service interface, there is only a simple a few words on the website. The same stock site can provide you with stock information, tourism airlines offering tourism and flight information. Too much, and sometimes updated, I think there will be a web service interface or portal, which will also become well-known entrance like Yahoo.

Some resources:

Framework SDK Beta 2

http://download.microsoft.com/download/visualstudionet/trial/2.0/w982kmexp/en-us/setup.exe

Microsoft ASP.NET Premium Edition If you have forget IIS for VS.NET Beta 2, then IIS is installed and installed. It can do not reinstall the entire vs.Net Beta 2

http://download.microsoft.com/download/visualstudionet /trial/2/w982kmexp/en-us/setup.exesoap Toolkit 2.0 SP2

Http://download.microsoft.com/download/xml/soap/2.0/w98nt42kme/en-us/soaptoolkit20.exe

Programming .net with c #

http://www.gotdotnet.com/featured_site/developmentor/assemblies2.pdf

XML SPY 4.0B2

http://www.xmlspy.com/download/beta/

Visual XSLT for vs.net beta2

http://downloads.activestate.com/visualxslt/visualxslt-1.0.0-beta3-1730.msi

MSDN Show: Introduction VS.NET Beta 2

Http://a138.ms.a.microsoft.com/f/138/1611/2H/download.microsoft.com/download/visualstudionet/utility/15/win98mexp/en-us/episode015.exe

Nice C # editor, can also develop and support Framework SDK Beta 2, the new version is also a dynamic function help

http://www.c-point.com/download/csharped.zip

SOAP EXTENSION with VISUAL Basic .NET

http://msdn.microsoft.com/msdn-files/026/002/305/vbsoapex.exe

转载请注明原文地址:https://www.9cbs.com/read-31056.html

New Post(0)