Click here to Skip to main content
15,895,746 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello

In my application I have a grid where my users can select the font, color and some other settings at runtime for the rows. With the selected color, font, and others values I create a new style in the codebehind. Then I set this style I set on the grid. --> This works perfect. But:

Now I like to save that style in the case I shutdown my application. After a restart I like so set the same style again. How can I access of the single elements of that style to serialize it.


Thanks
Posted
Comments
The Manoj Kumar 21-Nov-13 16:08pm    
And the problem is? Did you try XML or Binary serialization?

1 solution

As long as you save the settings somewhere like a configuration file (or database table), on app start up you should be able to check the file and run the same code that currently makes the changes. it will just happen without the users express direction.
 
Share this answer
 
Comments
Leung Yat Chun 23-Nov-13 0:38am    
e.g. this one, you just have to change the code in settings to update the UI.
http://stackoverflow.com/questions/845030/bind-to-a-value-defined-in-the-settings

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