Re: web service returned object type problem
From: Christoph Schittko [MVP] (INVALIDEMAIL_at_austin.rr.com)
Date: 01/03/05
- Next message: Mae Lim: "Re: Needed help on 'System.StackOverflowException'"
- Previous message: Christoph Schittko [MVP]: "Re: Needed help on 'System.StackOverflowException'"
- In reply to: Picho: "web service returned object type problem"
- Next in thread: erymuzuan: "Re: web service returned object type problem"
- Reply: erymuzuan: "Re: web service returned object type problem"
- Reply: Picho: "Re: web service returned object type problem"
- Reply: Picho: "Re: web service returned object type problem"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 3 Jan 2005 00:06:38 -0600
The same question just came up in
microsoft.public.dotnet.framework.webservices. As erymuzuan pointed out
.NET 2.0 will fix the issue once and for all, for now your best choice
is to edit the generated files, or even better, write a simple app or a
perl script that strips out all redundant classes generated from the
WSDL. There's an MSDN article that describes the edits you need [0].
The use of remoting is strongly discouraged [1] at this point with
respect to future interoperability issues and a programming model that
tempts developers to develop strongly coupled systems based on the
distributed object metaphor. Personally, I like the .NET Remoting
framework, and I am somewhat disappointed to see such a fine framework
go away, but knowing the issues ahead I can no longer recommend building
new distributed systems on .NET Remoting. At this point .NET Remoting
should strictly be used for intra-process/cross app domain scenarios.
HTH,
Christoph Schittko
MVP XML
http://weblogs.asp.net/cschittko
[0]
http://msdn.microsoft.com/library/en-us/dnservice/html/service07162002.a
sp
[1] http://weblogs.asp.net/cschittko/archive/2004/05/27/143388.aspx
> -----Original Message-----
> From: Picho [mailto:SPAM_picho@telhai.ac.il]
> Posted At: Sunday, January 02, 2005 12:31 PM
> Posted To: microsoft.public.dotnet.framework.webservices
> Conversation: web service returned object type problem
> Subject: web service returned object type problem
>
> Hi all.
>
> I have a webservice and a windows app.
> both of them reference the same class library called
WebServiceTest.Core
> that defines a class called Class1.
>
> the webservice exposes a method that looks like this:
>
> [WebMethod]
> public WebServiceTest.Core.Class1 GetClass1()
> {
> return new WebServiceTest.Core.Class1();
> }
>
> the windows app has a web reference to the webservice (and a reference
to
> the class library).
> I want (and even expected) the web-method to return a
> WebServiceTest.Core.Class1 object but instead it returns a
> WebServicesTest.Client.localhost.Class1 where:
> WrbServicesTest.Client is the windows app namespace
> localhost is the name of the webreference to the web service
> Class1 is some generated class that represents the return type.
>
> my question is simple:
>
> I need the original object. this is why both webservice and windows
app
> reference the shared assembly...
> what can I do?
> what am I doing wrong?
>
> thanx,
>
> Picho
- Next message: Mae Lim: "Re: Needed help on 'System.StackOverflowException'"
- Previous message: Christoph Schittko [MVP]: "Re: Needed help on 'System.StackOverflowException'"
- In reply to: Picho: "web service returned object type problem"
- Next in thread: erymuzuan: "Re: web service returned object type problem"
- Reply: erymuzuan: "Re: web service returned object type problem"
- Reply: Picho: "Re: web service returned object type problem"
- Reply: Picho: "Re: web service returned object type problem"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|