Author: Griffon2-6 | Posted on: 8/5/2009 8:16:51 AM | Views : 509

Hello,
I am currently creating a form that obtains various types of data from a user, mostly strings, but with a few instances of the DateTime data type. This makes it impractical to write everything into a text file line by line, and I thought that I would store all data into a structure and write the entire structure into a binary file. I am new to C# and ASP.NET, but I recall that in C, writing structures to a binary file was very simple and intuitive. However, it seems to be quite a bit more complicated in C#.
I've searched high and low for a method to do this, and have come across several solutions that suggested serializing the data and writing it to file. However, I also need a way to seek through the file to a certain location in order to append additional data or read a specific record, and this does not seem to be possible if serialization is used. Is there an alternative to using serialization such that seeking is possible?
Any h ...

Go to the complete details ...