For various reasons I moved a class (MovedClass) from assamblyA to assamblyB and also changed the namespace it was in. Everything else stayed the same.
But now I have a problem reading the Data I serealized before moving the class
Code:BinaryFormatter formatter = new BinaryFormatter(); StayedClass Stayed = null; Stayed= (StayedClass)formatter.Deserialize(stream);The exception says:Code:public StayedClass(SerializationInfo info, StreamingContext ctxt) { Moved = (MovedClass)info.GetValue("WebInfo", typeof(MovedClass)); // here it throws a exception }
What can I do? Its essential for me to move the Classes to the new assamby. Is there any way to tell desearialize that the class has moved?Code:Ein Objekt muss IConvertible implementieren. which is german for: Object must implement IConvertible




Reply With Quote
