Yes Bonnie, it does look strange. In VS2005 there was an option to add a Web Reference but now in VS2008 we add a Service Reference in VB.Net. I think my confusion stems from the fact that I am using a third party WebService which is poorly documented outside of the WSDL.
Thanks
]Glenn
>This stuff looks rather strange Glenn. How did you add the reference? It should have been simply "Add Web Reference" to your project(unless the VB IDE differs significantly from the C# IDE).
>
>In addition to the WSDL that gets generated, there should also be a reference.vb file which is basically the class that you instantiate to use the WS. The class will have the namespace containing the name you used when you added it. So, for example, if I add a web reference in my MainControl project and I call it PersonnelWS. The reference.cs (.vb in your case) that gets generated will have a namespace of MyCompany.MyApp.WinUI.MainControl.PersonnelWS, and the partial class that gets generated will be the same class name as the web service class, Personnel in my case.
>
>In C#, all I would do to instantiate this WS is this:
>
>
>// Declaration
>PersonnelWS.Personnel oWS;
>
>// Instantiation ... usually done in the constructor
>this.oWS = new PersonnelWS.Personnel(); // you would obviously use me.oWS
>
>
>Actually, we also use a Factory class for instantiating our web services, but the concept is the similar.
>
>Then you just call the methods of the class, like any other methods on classes. Intellisense will show you the methods available.
>
>Does this help?
>
>~~Bonnie
>
>
>
>
>
>>I need to access and execute methods on a web service from a VB.Net class in VS2008. So far I have added a Service Reference to the Project for the WebService (WSDL Reference) and it properly describes the Services and Operations. My problem is now I have no idea as to how to Use it. For instance this WS has a service called ContentCafeHTTPGet with three available operations
- Single
- XMLPost
- XMLString
How would I instanciate this service so that I could execute the Single operation?
>>
>>Thanks
>>
>>Glenn