5 Answers, 1 is accepted
0
Hello Azees,
GridLines and CSS borders are different things. RadGrid skins use the border CSS property, while the GridLines property uses the rules HTML attribute. You cannot remove CSS borders with the GridLines property.
Please add the following CSS rules to your web page (web site) in order to remove the borders from the header and data cells:
th.GridHeader_Office2007,
th.ResizeHeader_Office2007,
tr.GridRow_Office2007 td,
tr.GridAltRow_Office2007 td,
tr.GridFooter_Office2007 td,
tr.GridGroupFooter_Office2007 td
{
border: 0;
}
th.GridHeader_Office2007,
th.ResizeHeader_Office2007
{
border-bottom:1px solid #9EB6CE;
}
The second rule will preserve the bottom borders for the header cells.
Best wishes,
Dimo
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
GridLines and CSS borders are different things. RadGrid skins use the border CSS property, while the GridLines property uses the rules HTML attribute. You cannot remove CSS borders with the GridLines property.
Please add the following CSS rules to your web page (web site) in order to remove the borders from the header and data cells:
th.GridHeader_Office2007,
th.ResizeHeader_Office2007,
tr.GridRow_Office2007 td,
tr.GridAltRow_Office2007 td,
tr.GridFooter_Office2007 td,
tr.GridGroupFooter_Office2007 td
{
border: 0;
}
th.GridHeader_Office2007,
th.ResizeHeader_Office2007
{
border-bottom:1px solid #9EB6CE;
}
The second rule will preserve the bottom borders for the header cells.
Best wishes,
Dimo
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Bill Siegler
Top achievements
Rank 1
answered on 17 Mar 2009, 02:52 PM
This solution was working for the last 2008 release. I just updated to the Q1 2009 controls and this doesn't work anymore. Any thoughts?
0
Hello Bill,
The CSS rules for RadGird Q1 2009 should be:
Sincerely yours,
Dimo
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
The CSS rules for RadGird Q1 2009 should be:
div.RadGrid_Office2007 .rgHeader, |
div.RadGrid_Office2007 th.rgResizeCol, |
div.RadGrid_Office2007 .rgRow td, |
div.RadGrid_Office2007 .rgAltRow td, |
div.RadGrid_Office2007 .rgFooter td |
{ |
border: 0; |
} |
div.RadGrid_Office2007 .rgHeader, |
div.RadGrid_Office2007 th.rgResizeCol |
{ |
border-bottom:1px solid #9EB6CE; |
} |
Sincerely yours,
Dimo
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Bill Siegler
Top achievements
Rank 1
answered on 17 Mar 2009, 04:22 PM
Thanks this worked fine. One more question: if you have a page with 2 grids and you want one to have grid lines and the other to not have them, how can you apply the styles to a single grid?
0
Hi Bill,
You can set a custom CssClass to all RadGrids, which you want to NOT have borders and replace all occurrences of "RadGrid_Office2007" with the custom CSS class in the rules above. For example:
<telerik:RadGrid CssClass="MyCustomClass" />
div.MyCustomClass .rgHeader,
div.MyCustomClass th.rgResizeCol,
div.MyCustomClass .rgRow td,
div.MyCustomClass .rgAltRow td,
div.MyCustomClass .rgFooter td
{
border: 0;
}
div.MyCustomClass .rgHeader,
div.MyCustomClass th.rgResizeCol
{
border-bottom:1px solid #9EB6CE;
}
Greetings,
Dimo
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
You can set a custom CssClass to all RadGrids, which you want to NOT have borders and replace all occurrences of "RadGrid_Office2007" with the custom CSS class in the rules above. For example:
<telerik:RadGrid CssClass="MyCustomClass" />
div.MyCustomClass .rgHeader,
div.MyCustomClass th.rgResizeCol,
div.MyCustomClass .rgRow td,
div.MyCustomClass .rgAltRow td,
div.MyCustomClass .rgFooter td
{
border: 0;
}
div.MyCustomClass .rgHeader,
div.MyCustomClass th.rgResizeCol
{
border-bottom:1px solid #9EB6CE;
}
Greetings,
Dimo
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.