Deserialization Problem pls HELP!

I posted a thread three lines down bellow this one, and after 200 views nobody had anything to say about it. I can't believe it, so I guess I did not ask the question right. Let me rephrase:

I have a web service running on a server (http://domain.com/service wsdl). When I send requests, they are going there, the parameters get deserialized, get processed, and get returned. Now, when the response comes back to the client app, if the response contains a complex structure(ei. class, array) the client app. cannot deserialize it. The function is something like ItemInfo[] Foo(Report) and the error is:

Parse Error, no assembly associated with Xml key  a1:http://schemas.microsoft.com/clr/nsassem/iPACSAPI/IIntegration%2C%20Version%3D1.0.2063.18125%2C
%20Culture%3Dneutral%2C%20PublicKeyToken%3Dnull ItemInfo

Now, after years of SOAP experience out there, there must be somebody that run across this issue!!!!

I really appriciate your help!
Stan


Answer this question

Deserialization Problem pls HELP!

  • Mitchell Vincent

    For the error message, seems like the ItemInfo[] object is null or empty. Do you are saving the key into a serialized property .

  • BrianXL

    It looks like the error is indicating that the ItemInfo type cannot be found on the client for deserialization.  Do you have the same assembly used on the server shared out to the client   .NET Remoting requires that the contract (interfaces or MBRO) and data types (inputs and outputs to the methods) be available to the applications on both client and server.

    Hope that helps.

    Matt



  • joe20050

    I had a similar situation with deserealization complex structures but it doesn’t have anything to do with web services or other thing but the serialization itself. When you serialize and try to deserialize the same array, class, etc.  and you compare the objects with one that had not been serialized-deserialized it seems not be the same. Even if the object type looks exactly the same. I think the problem is with a change in the object type when you deserialize an object, it looks ok but intrinsecally there something wrong. I turn around this problem copying each element of the structure into another newly created of the correct type. You can do this right after the deserialization process.

    Best regards

  • sjmueller

    Offhand it seems you are attempting to deserialize a type that isn't recognized by the client. Be advised that simply having the same class (even if it's the same source file) on the client and server isn't good enough; a type is identified by its container assembly as well as its name.

    In order to use the same type on both client and server you have to either distribute a shared assembly (used by the server as well!) containing the type, or use "soapsuds -oa" (soapsuds.exe is a tool contained in the .NET SDK in your <program files>\Microsoft Visual Studio 2003\SDK\v1.1\bin directory) to generate the appropriate stub type. I have no experience with the latter technique, so do let me know if/how it worked for you.



  • Deserialization Problem pls HELP!