Reputation: 2509
I am looking for ways to store data in a Windows Forms application in .NET. I want to make the input data of a system persistent, so when I close my program and open it again, the data is retrieved.
Which ways of doing this exist besides creating a linked database? Examples are gladly appreciated.
Upvotes: 3
Views: 1808
Reputation: 62159
Examples? Do your homework yourself :)
Anyhow, possible ways are:
Which makes sense depends on what the application DOES and other scenarios around it. A fast answer is not really possible without knowing more.
Upvotes: 0
Reputation: 14249
If your data is not mission critical (e.g. user preferences), you could just serialise your objects to file, and de-serialise them next time the app is loaded.
Upvotes: 1
Reputation: 122684
There are dozens of different ways to store data. It completely depends on what data. Is it:
And so on... there are different solutions for every storage requirement and many projects make use of more than one at a time.
Upvotes: 19
Reputation: 166626
An easy way would be to make use of XML.
Using XML in C# in the simplest way
Read/Write Xml document with FileStream
Upvotes: 1