A little help

A

aaa

Up until now I have used MS Web Services which are fairly straight-forward.
Now I am being asked to use some third party web services which I do not
find nearly as intuitive.

Questions:
1. I have a URL for a wsdl file only no URL to an aspx page such as with
MS. I have used this wsdl to make a proxy file. Do I still need to make a
"Web Reference" such as with an aspx file or does the proxy stub suffice?
2. I only see properties (not methods) in any of these classes. I am not
sure how I am supposed to initiate any work?
3 In their documentation they have examples of XML for making their SOAP
calls (are they kidding me)? They want me to manually create all of the XML
neccessary for the SOAP calls to their services? Why bother with web
services?
 
B

Bruce Johnson [C# MVP]

Perhaps the easiest thing for you to do will be the create a proxy class
using the WSDL that they provide. The class should then have an interface
that you can interact with more naturally. If all that you have is the WSDL
file, then you can use the wsdl.exe command directly to generate the .cs or
..vb proxy class. This is the command that Add Web Reference calls under the
covers and it takes either a URL or a local path as one of the parameters.
Once the class is created, just add it to your project and use it like any
other class. It should take care of creating all of the necessary XML to
communicate with the web service.

Hope that helps.

Bruce Johnson [C# MVP]
http://www.objectsharp.com/blogs/bruce
 
B

Bruce Johnson [C# MVP]

Probably the easiest thing to do will be to create the proxy class manually.
This should solve the issues you describe in 2 and 3. The way to do this is
to use the wsdl.exe command. There is documentation for it at
http://msdn.microsoft.com/library/d...WebServicesDescriptionLanguageToolWsdlexe.asp.
But the most important thing is that it can take either a URL or a file path
from the command line and generate a proxy class in either vb.net or c#.
This is the tool that the Add Web Reference uses under the covers. Once the
class is generated, add it to your project and you should be good to go.

Hope this helps.

Bruce Johnson [C# MVP]
http://www.objectsharp.com/blogs/bruce
 
A

aaa

True, I did do that and I have generated the appropriate classes
But, the odd thing and this isn't MS related, there are no methods (other
than the base methods for the ws) only properties and it appears that they
want me to format abunch of XML (to their specs) and transmit to them the
data that way. Does that sound appropriate to you? Is that standard with
non-MS 3rd party web services? I thought the whole idea was make a web
reference (like you would a local reference) and you have exposed properties
and methods and you can go to town and everything is transparent.

Bruce Johnson said:
Probably the easiest thing to do will be to create the proxy class manually.
This should solve the issues you describe in 2 and 3. The way to do this is
to use the wsdl.exe command. There is documentation for it at
http://msdn.microsoft.com/library/d...WebServicesDescriptionLanguageToolWsdlexe.asp.
But the most important thing is that it can take either a URL or a file path
from the command line and generate a proxy class in either vb.net or c#.
This is the tool that the Add Web Reference uses under the covers. Once the
class is generated, add it to your project and you should be good to go.

Hope this helps.

Bruce Johnson [C# MVP]
http://www.objectsharp.com/blogs/bruce

aaa said:
Up until now I have used MS Web Services which are fairly straight-forward.
Now I am being asked to use some third party web services which I do not
find nearly as intuitive.

Questions:
1. I have a URL for a wsdl file only no URL to an aspx page such as with
MS. I have used this wsdl to make a proxy file. Do I still need to make a
"Web Reference" such as with an aspx file or does the proxy stub suffice?
2. I only see properties (not methods) in any of these classes. I am not
sure how I am supposed to initiate any work?
3 In their documentation they have examples of XML for making their SOAP
calls (are they kidding me)? They want me to manually create all of the XML
neccessary for the SOAP calls to their services? Why bother with web
services?
 
B

Bruce Johnson [C# MVP]

Yes and no. The yes is that formatting a bunch XML according to a spec is
the defintion of SOAP without all of the nice supporting classes ;). The no
is that if they want they're XML formatted based on a spec, they should have
included a schema in the WSDL file. And if they did, then the generated
proxy class should have classes defined that will serialize into the
appropriate XML. If they didn't, they I'd have to extend my sympathies and
suggest that the writers of the web service are a touch clueless when it
comes to how to convey their web service's interface.

Bruce Johnson [C# MVP]
http://www.objectsharp.com/blogs/bruce

aaa said:
True, I did do that and I have generated the appropriate classes
But, the odd thing and this isn't MS related, there are no methods (other
than the base methods for the ws) only properties and it appears that they
want me to format abunch of XML (to their specs) and transmit to them the
data that way. Does that sound appropriate to you? Is that standard with
non-MS 3rd party web services? I thought the whole idea was make a web
reference (like you would a local reference) and you have exposed properties
and methods and you can go to town and everything is transparent.

Bruce Johnson said:
Probably the easiest thing to do will be to create the proxy class manually.
This should solve the issues you describe in 2 and 3. The way to do this is
to use the wsdl.exe command. There is documentation for it at
http://msdn.microsoft.com/library/d...WebServicesDescriptionLanguageToolWsdlexe.asp.
But the most important thing is that it can take either a URL or a file path
from the command line and generate a proxy class in either vb.net or c#.
This is the tool that the Add Web Reference uses under the covers. Once the
class is generated, add it to your project and you should be good to go.

Hope this helps.

Bruce Johnson [C# MVP]
http://www.objectsharp.com/blogs/bruce

aaa said:
Up until now I have used MS Web Services which are fairly straight-forward.
Now I am being asked to use some third party web services which I do not
find nearly as intuitive.

Questions:
1. I have a URL for a wsdl file only no URL to an aspx page such as with
MS. I have used this wsdl to make a proxy file. Do I still need to make a
"Web Reference" such as with an aspx file or does the proxy stub suffice?
2. I only see properties (not methods) in any of these classes. I am not
sure how I am supposed to initiate any work?
3 In their documentation they have examples of XML for making their SOAP
calls (are they kidding me)? They want me to manually create all of the XML
neccessary for the SOAP calls to their services? Why bother with web
services?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,997
Messages
2,570,240
Members
46,830
Latest member
HeleneMull

Latest Threads

Top