Hi,
I have a WebService which supplies an object. Now when I add a
"Web-Reference" in VS.2003 the proxy class doesn't return an instance
of that object, but it's own "implementation" of it, which is not what
I need!
I know that in theory I don't always have access to the original
object-types from the "client" app, but in my case I have bound the
"common" dll to both applications.
Is there a way to get the serialized version of the "real" object,
instead of having a proxy-class generated?
regards, Tilli
Drew Marsh - 26 Nov 2004 21:19 GMT
> I have a WebService which supplies an object. Now when I add a
> "Web-Reference" in VS.2003 the proxy class doesn't return an instance
[quoted text clipped - 7 lines]
> Is there a way to get the serialized version of the "real" object,
> instead of having a proxy-class generated?
Writing the proxy yourself is probably the only answer to this. You gotta realize that any .NET type information ceases to exist once the web service generates the WSDL and schema for your types, there's no way that Add Web Reference, more specifically wsdl.exe, has any clue about .NET types. So, instead, it generates it's own wrapper types based off of the WSDL/schema. If you want to get fancier, you need to write the proxy by hand.
HTH,
Drew
Tilfried Weissenberger - 30 Nov 2004 09:26 GMT
I understand, thank you!
regards, Tilli