473,508 Members | 2,425 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

SoapFormatter throws System.Exception when deserializing non-compatible versions

Given:

public class MyClass{
public String MyPropertyOne;
}

I have a soap document created by serializing an instance of a previous
version of MyClass. However, now MyClass looks like:

public class MyClass{
public String MyPropertyOne;
public String MyPropertyTwo;
}

If I now use the SoapFormatter to deserialize the older instance of MyClass,
I get an exception that looks like:

"Wrong number of Members. Object MyClass has 2 members, number of members
deserialized is 1"

I would like the older instance to continue deserializing, even though it
might not be "binary compatible". Is there an easy way to do this?

TIA//


Nov 19 '05 #1
0 1252

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
2056
by: Philip Reed | last post by:
I'm trying to write a preferences-handling infrastructure that serializes prefs to XML. Basically I want to read in a common "default" prefs set, then read in the user's prefs and override the...
1
2278
by: Philip K | last post by:
I was trying to use Soap serialisation to save some systems settings how ever it fails if the settings contain a Font object, works fine if the Font object is not in the object being serialised. ...
0
1427
by: craig | last post by:
Hi, I'm new to all this and having tremendous difficulty trying to deserialize the following: <soap-env:Envelope...
1
2660
by: Jim S | last post by:
I have an application where I have to make a tree of objects. To do this, I have my own node class. At certain points in the application, I need to save data. I am having a problem with the...
2
3739
by: Phillip Galey | last post by:
I have an object called Place which contains only string properties and has the <Serializable()> flag before the class name declaration. I also have a collection object called Places, which is...
0
1077
by: GrandpaB | last post by:
I have an error that I have not been able to find. Any insight you can offer would be most appreciated. I believe that the problem is associated with the SoapFormatter. The application allows...
4
10156
by: laplas | last post by:
Hello, what is the internal difference between them in FW 2.0? I'm trying to serialize SqlConnectionInfo from SQL SMO and Soap works just fine but XML throws an exception SqlConnectionInfo has...
0
1077
by: Clas | last post by:
Hi! I have some questions about exceptionshandling when using webservices. I want to be able to get the original exception back from the webservice-soapexception. I have used the SoapFormatter to...
3
3979
by: Wiebe Tijsma | last post by:
Hi, I'm trying to serialize a KeyedCollection with the SoapFormatter, however I'm getting the exception: System.Runtime.Serialization.SerializationException: Soap Serializer does not support...
0
1094
by: Alphamacaroon | last post by:
All, I am using the SoapFormatter class to parse/deserialize SOAP/RPC calls from a remote client. The SoapFormatter works like a charm when the message contains simple parameter types (like...
0
7224
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7118
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7323
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7379
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7493
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5625
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4706
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3192
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
415
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.