This is a migrated thread and some comments may be shown as answers.

Style grid on runtime

1 Answer 78 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Stephan
Top achievements
Rank 1
Stephan asked on 10 Apr 2013, 10:52 AM

Requirement:
Set the font, the foreground and background color of the grid (headerrow and and "datarow) at runtime over a context menu. Save it and reload theses on restart.

Actual situation:
- We have implemented a contextmenu for the grid with an attached property. On attaching it "taps" the grid and it is possible to enable and disable single columns over this context menu which opens on right mouse click on header.
- Additional to that, we implemented an additional attached property which also "taps" to the grid OnAttaching, which allows to save the grid settings (columns width, enable columns, filter...) to a file. Add restart the grid takes this settings add set the saved values.
- The grid is styles are in different resource dictionaries which will be added to Application.Current.Resources.MergedDictionaries

Problem:
Now, I would like to add some additional context menu (this works) with color pickers and a font picker (does telerik have a font picker in future for wpf?).
If an new color is selected I created a new style (in code behind) an added it to the resources of the grid. This runs, but now I can't find a solution to save this style like the over values. 

How can I save this lokal style? Is this solution wrong? Do you have an better simpler solution?

Thanks & Regards

 

1 Answer, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 15 Apr 2013, 11:28 AM
Hello,

I am afraid that we do not offer a color picker for RadGridView. 

Greetings,
Didie
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
GridView
Asked by
Stephan
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Share this question
or