Webservice that references other .Net libraries

M

Mantorok

Hi all

I have a web service and it is going fine until I call a method that returns
an object that is based on a class from a referenced .net assembly.

The problem is my calling code doesn't know anything about the class that
the web-service is using, how do I ensure that my calling code is aware of
the classes/objects being returned by the consumed web-service?

Hope that makes sense
Kev
 
P

Peter Rilling

Make sure your client has the returned class available so that it can be
deserialized and instantiated, or make sure that you only return either
primitive types or types that are available in the framework. Obviously if
the class is not visible to your code, then it cannot create an instance of
it.
 
B

Bruce Barker

build your own project file for the proxy stub, and add references (or
include the class code) for all objects the webservice may return.

-- bruce (sqlwork.com)
 
M

Mantorok

Bruce

How do i do this? When I include references to the project that contains
the classes it claims that the web-service is returning different types!

Kev
 
P

Peter Rilling

It probably is because the serialization puts the entire namespace and such
in the encoded information.

Is it possible for you to get the binaries that are running from your
webservice? You may actually need to bind to those.
 

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
474,432
Messages
2,571,682
Members
48,796
Latest member
Greg L.

Latest Threads

Top