stuck with WSDL in VB.net win forms
-
grettings gentlemen i've been only given a WSDL file and i have to use that file in a VB.net win forms aplication to consume the given web service. i've read much about WSDL, SOAP, UDDI, web services, etc. everyone points very clear what is what and how its supposed to work. but none makes clear the "how to introduce the wsdl file into the project" i just want to know how to use the wsdl file to reach its web methods and how to save the resulting xml from the methods. my idea is to insert the wsdl into the project. then a button triggers the code to call the webmethod, then the result is saved into a xml, then with a xml data adapter turn this xml into a dataset. then using the dataset fill a datagridview control to show it to the user. i simply dont know how... any help would be appreciated, later with this experience i prommise im gonna make an article about this "WSDL in practice, step by step", trying to be not so specific about the theory but in the practice. thanks for your time
-
grettings gentlemen i've been only given a WSDL file and i have to use that file in a VB.net win forms aplication to consume the given web service. i've read much about WSDL, SOAP, UDDI, web services, etc. everyone points very clear what is what and how its supposed to work. but none makes clear the "how to introduce the wsdl file into the project" i just want to know how to use the wsdl file to reach its web methods and how to save the resulting xml from the methods. my idea is to insert the wsdl into the project. then a button triggers the code to call the webmethod, then the result is saved into a xml, then with a xml data adapter turn this xml into a dataset. then using the dataset fill a datagridview control to show it to the user. i simply dont know how... any help would be appreciated, later with this experience i prommise im gonna make an article about this "WSDL in practice, step by step", trying to be not so specific about the theory but in the practice. thanks for your time
If you right click on the project and choose 'add web reference', you can import a web service by passing in the URL. This will download the WSDL, as it happens.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
-
If you right click on the project and choose 'add web reference', you can import a web service by passing in the URL. This will download the WSDL, as it happens.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
-
umm, i missed to say i only have a wsdl file, i havent been given a url... i was wondering if i could get the url from the swdl file
If you can't get the URL, then you have no hope at all, a web service can't work without a URL to look up. You could try pointing to the WSDL locally and see if it builds a reference from there.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
-
If you can't get the URL, then you have no hope at all, a web service can't work without a URL to look up. You could try pointing to the WSDL locally and see if it builds a reference from there.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
thanks Christian, u have made some serius point clear, now i understand my situation. ill request that url and then ill start coding. just another thing, when calling the web method it returns me a xml in this format: 100PRE MI ROBERT HC2733 EQA 22.61 2 2 05-02-2007 06:00:00 01-03-2007 10:00:00 -0.9166666667 -80.7000000000 0 0 NAV how do i store it or do i just put it as an input to a xml data adapter to turn it to a dataset? im not very clear with that modified on Tuesday, April 1, 2008 12:34 PM
-
thanks Christian, u have made some serius point clear, now i understand my situation. ill request that url and then ill start coding. just another thing, when calling the web method it returns me a xml in this format: 100PRE MI ROBERT HC2733 EQA 22.61 2 2 05-02-2007 06:00:00 01-03-2007 10:00:00 -0.9166666667 -80.7000000000 0 0 NAV how do i store it or do i just put it as an input to a xml data adapter to turn it to a dataset? im not very clear with that modified on Tuesday, April 1, 2008 12:34 PM
-
Whaty ou do with the XML is entirely up to you. If those name attributes refer to properties of an object, odds are that .NET will define the object and you'll get back an instance of that object when you use .NET to talk to the web service.
Christian Graus - Microsoft MVP - C++ Metal Musings - Rex and my new metal blog "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )