I have some interop problems that prevent the WSDL.exe from creating a proxy class. I just want to create my own proxy class and see if I can get the web service working with a .net client. I have Mr. Ballinger's great book ".NET Web services" but he really
does not go into to much detail on creating proxy classes by hand. I think that most MS people assume that the world revolves around MS.....I call it the “MS Code Copernicus theory”. So I struggled last night with trying to create some client code that would
work. // ------------------------------------------------ // @ Keith Ballinger – “.NET Web Services” // ------------------------------------------------ [WebServiceBinding(“MyBinding”, “http://namespace”)] public class CustomServiceMethods: SoapHttpClientProtocol{
public CustomServiceMethods(){ this.Url = “http://remoteserver”; } [SoapRpcMethod(http://SoapActionUrl)] public string Authenticate(string in0, string in1){ object [] args = {in0,in1}; object [] responseMessage = this.Invoke(“Authenticate”, args); return ((string)
(responseMesage[0])); } }//~ class This was as close as I got….the problem was that my return structure from the service endpoint keeps resolving to XmlNode[] instead of a string type message. I realize that SoapRpc is encoded already…. I was getting
stuff back once but I can’t recall what I did! LOL p.s. this works if I use the SOAP toolkit ……I just don’t want to use it…
Maybe you should post in the Studio forum... something to the effect of "Studio creates a bad proxy class when referencing some webservices." I'm sure someone there will want to defend Studio and tell you why it's not Studio's fault, and that might give you
another clue to work on :) Travis
None
0 Points
86 Posts
Docs on Creating my own Proxy Class?
Oct 03, 2003 12:46 PM|XMLViking|LINK
// ------------------------------------------------ // @ Keith Ballinger – “.NET Web Services” // ------------------------------------------------ [WebServiceBinding(“MyBinding”, “http://namespace”)] public class CustomServiceMethods: SoapHttpClientProtocol{ public CustomServiceMethods(){ this.Url = “http://remoteserver”; } [SoapRpcMethod(http://SoapActionUrl)] public string Authenticate(string in0, string in1){ object [] args = {in0,in1}; object [] responseMessage = this.Invoke(“Authenticate”, args); return ((string) (responseMesage[0])); } }//~ class
This was as close as I got….the problem was that my return structure from the service endpoint keeps resolving to XmlNode[] instead of a string type message. I realize that SoapRpc is encoded already…. I was getting stuff back once but I can’t recall what I did! LOL p.s. this works if I use the SOAP toolkit ……I just don’t want to use it…None
0 Points
81 Posts
Re: Docs on Creating my own Proxy Class?
Oct 03, 2003 01:09 PM|travislaborde|LINK