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

Font in RADGRID

4 Answers 187 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bharat
Top achievements
Rank 1
Bharat asked on 16 Nov 2010, 10:19 AM
Hi All,

how to change the font of RADGRID column.
I am using datarelation in Grid.  Autogenerated column = true


Bharat Rathore

4 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 16 Nov 2010, 10:26 AM
Hello Bharat,


If you want to change the font for entire grid, then adding the following CSS on page will work for you.

CSS:
<style type="text/css">
    .RadGrid, .RadGrid .rgMasterTable, .RadGrid .rgDetailTable, .RadGrid .rgGroupPanel table, .RadGrid .rgCommandRow table, .RadGrid .rgEditForm table, .RadGrid .rgPager table, .GridToolTip
    {
        font-family: Verdana !important;       
    }
</style>



-Shinu.
0
Bharat
Top achievements
Rank 1
answered on 16 Nov 2010, 10:31 AM
Hi ,
I want to change a font of single column.
Autogeneratedcolumns= true
0
Daniel
Telerik team
answered on 16 Nov 2010, 11:41 AM
Hello Bharat,

Try the following approach:
protected void RadGrid1_ColumnCreated(object sender, GridColumnCreatedEventArgs e)
{
    if (e.Column.UniqueName == "CategoryName")
    {
        e.Column.ItemStyle.Font.Name = "Wingdings";
    }
}

I hope this helps.

Kind regards,
Daniel
the Telerik team
Browse the vast support resources we have to jumpstart your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Bharat
Top achievements
Rank 1
answered on 16 Nov 2010, 11:59 AM
Thank you so much
My Issue is resolved

Bharat Rathore
Tags
General Discussions
Asked by
Bharat
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Bharat
Top achievements
Rank 1
Daniel
Telerik team
Share this question
or