Hello,
In our .NET application we depend on binary serialization for our application project files. The main project class file uses the following method to serialize itself (note all exceptionhandling is removed for clarity).
public void ProjectSerialize(string filename)
{
Stream s = File.Open(filename, FileMode.Create);
BinaryFormatter b = new BinaryFormatter();
b.Serialize(s, this);
}
The class has many methods and properties that are stored. Now everything works fine, however when we want to release a new version of the application that has a new version of the project class, we are not compatible anymore with earlier versions. I know it is a design error, since of course i had to use my own defined serialization and I should have not depend on .NET for this important type of files.
Now my question, how can I read my older serialized project files? Is there a format I should know, how did .NET serialize in the first place? I just want my customers to be compatible with the older fileformat, but I don't now how to write a file converter for the old stored project files.
Thanks,
Erik