Click here to Skip to main content
15,890,557 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
So in my xaml window I have a TextBox. User starts my application inputs some values in to it and presses a button or hits Enter. He closes an app. Opens it up again. How to make his inputs be saved in that TextBox in WPF and retrive again the last inputed values when he starts the application next time
Posted

1 solution

 
Share this answer
 
Comments
amitkarnik2211 22-Jan-11 3:36am    
Actually I hv 1500 or more TextBox So is it that I will hv to assign Settings to every text box
DaveAuld 22-Jan-11 3:41am    
Nope, what you could do is create a custom Configuration Class, and use it to read the value of all controls in the collection and save them out to a custom xml file, and on startup read them back in.
Alternativly, you bind each of the text boxes to the application setings.
1500: That is a lot of settings to have in an application!
DaveAuld 22-Jan-11 4:58am    
Did you look at this article on CP which was linked within the blog post above; http://www.codeproject.com/KB/dotnet/user_settings.aspx
amitkarnik2211 22-Jan-11 5:02am    
Thanks This is Helping i Think so let me try
amitkarnik2211 23-Feb-11 2:26am    
Thanks Dave It worked

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900