3 Answers, 1 is accepted
0

Princy
Top achievements
Rank 2
answered on 13 Sep 2011, 04:01 PM
Hello Ron,
One suggestion is to override the default CSS like below.
CSS:
Another approach is to set the style in aspx itself.
aspx:
Thanks,
Princy.
One suggestion is to override the default CSS like below.
CSS:
.RadGrid_Sunset .rgRow td
{
height
:
80px
!important
;
background-color
: Yellow
!important
;
}
.RadGrid_Sunset .rgAltRow td
{
height
:
80px
!important
;
background-color
: Black
!important
;
}
Another approach is to set the style in aspx itself.
aspx:
<
AlternatingItemStyle
BackColor
=
"Red"
Height
=
"60px"
/>
<
ItemStyle
BackColor
=
"Yellow"
Height
=
"20px"
/>
Thanks,
Princy.
0

Ron
Top achievements
Rank 1
answered on 13 Sep 2011, 04:53 PM
I figure I'd do it in css instead of within the grid because I will have about 8 grids across this site using the same scheme. I thought it would be easier. "
.RadGrid_Sunset" is that the name of a skin and is that exactly what i would enter into css script?
0

Princy
Top achievements
Rank 2
answered on 21 Sep 2011, 11:23 AM
Hello Ron,
The Skin applied to RadGrid is 'Sunset'. Once you set the above css in page it will apply the css style to all Radgrid in that page(which has Skin 'Sunset'). Hope this information helps.
ASPX:
CSS:-
Thanks,
Princy.
The Skin applied to RadGrid is 'Sunset'. Once you set the above css in page it will apply the css style to all Radgrid in that page(which has Skin 'Sunset'). Hope this information helps.
ASPX:
<
telerik:RadGrid
ID
=
"RadGrid1"
runat
=
"server"
AutoGenerateColumns
=
"true"
DataSourceID
=
"SqlDataSource1"
Skin
=
"Sunset"
>
<
MasterTableView
>
<
Columns
>
</
Columns
>
</
MasterTableView
>
</telerik:RadGrid
>
<
telerik:RadGrid
ID
=
"RadGrid2"
runat
=
"server"
AutoGenerateColumns
=
"true"
DataSourceID
=
"SqlDataSource1"
Skin
=
"Sunset"
>
<
MasterTableView
>
<
Columns
>
</
Columns
>
</
MasterTableView
>
</
telerik:RadGrid
>
CSS:-
<style type=
"text/css"
>
.RadGrid_Sunset .rgRow td
{
background-color
: Yellow
!important
;
}
</style>
Thanks,
Princy.