I am soap serializing multiple objects and appending them to a single file,then I am desirializing to have all the objects to tree view
I am using this part of code of desirialization
FileStream fs = new FileStream(fName, FileMode.Open);
while (fs.Position < fs.Length)
{
arraylizt.Add(sf.Deserialize(fs));
}
It works well, but sometimes the last object in the file is not desirialized.
I am not getting why its not desirializing the final object sometimes
Please help me or suggest me any other way to deserialize