Search code examples
c#tabsstoring-data

Good way to store tab data


I am working on a program with a tabbed interface, my problem is that I need a way to store the data in each tab so it will be the same as it was when the program was shut off. I would like to use a database, but Visual C# express 2010 is not the best with databases, I am thinking of using simple text files, but I think there is probably a better way to do it, any thoughts?


Solution

  • If you have strongly typed entities and are using Windows Forms Databinding, then you could just serialize the bound entities (e.g. using XmlSerializer) when exiting your app, and then reserialize them when loading the form when the app restarts.