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

GridViewSelectColumn Checkbox Styling

3 Answers 117 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Neha
Top achievements
Rank 1
Neha asked on 05 Apr 2012, 09:59 AM
Hello Telerik,

I wanted to customize GridViewSelectColumn styling. I got a reference of the GridViewSelectColumn appearence in one of the forums mentioned below:-
http://www.telerik.com/community/forums/silverlight/gridview/gridviewselectcolumn-appearnace.aspx

The issues that I am facing:-
1. If I use this above mentioned link styling then it applies to all the checkboxes in the Application not just the GridViewSelectColumn checkbox. Can you please let me know how do I apply the styling only for the check boxes in the GridViewSelectColumn?
2. Or How do I get a reference to the GridViewSelectColumn checkbox so I can apply the styling explicitly?
3. Or If its possible can you please provide the detailed style template for GridViewSelectColumn?


Thanks,
Neha

3 Answers, 1 is accepted

Sort by
0
Vanya Pavlova
Telerik team
answered on 10 Apr 2012, 08:20 AM
Hello Neha,

 
You may try to isolate the style targeted at the standard CheckBox at the resource level of your grid. GridViewSelectColumn is a column which holds a single CheckBox bound to the IsSelected property of the row. Internally it does not provide any editing logic and placing the style at the Resources of your RadGridView should resolve the issue. Will you verify how this works for you? 



Kind regards,
Vanya Pavlova
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Neha
Top achievements
Rank 1
answered on 11 Apr 2012, 07:18 AM
Hello Vanya,

I have to mention by styling at some central repository since I have many gridviews (so I cannot mention the styling at Page/Grid level. As of now I have mentioned by styling at the in Resource Dictionary.)

Here is another issue which I am facing with the approach suggested in the previous Post. The Background of my standard checkbox is some Gradient color but that of the GridViewSelectColumn is Gray.

By using the approach suggested in "http://www.telerik.com/community/forums/silverlight/gridview/gridviewselectcolumn-appearnace.aspx", how do I conditionally set the Background if the checkbox is from GridViewSelectColumn or as the standard checkbox? (Other than defining 2 styles with only Backgrounds differents)

Presently, to get this working I have set the Checkbox style in the ControlTemplate of the GridViewHeaderCell &
GridViewCell.Is there any other way to do this?

Thanks,
Neha
0
Vlad
Telerik team
answered on 12 Apr 2012, 07:52 AM
Hello,

 We added two new properties for GridViewSelectColumn in order to help developers in such scenarios:

- HeaderCheckBoxStyle: Sets the style for the CheckBox in the column Header (visible in case of multiple selection)
- CheckBoxStyle: Sets the style for the CheckBoxes in column cells.

This change will be part of our next internal build (next week).

All the best,
Vlad
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
GridView
Asked by
Neha
Top achievements
Rank 1
Answers by
Vanya Pavlova
Telerik team
Neha
Top achievements
Rank 1
Vlad
Telerik team
Share this question
or