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

Change font of RadGrid Cell

3 Answers 260 Views
Grid
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 31 Jul 2010, 09:40 PM
Hello:

I've implemented JavaScript so that the data in the first column of the RadGrid is a clickable link, clicking the link loads an informaiton form for whatever cell is clicked.

Is there a way to change the font of this cell so that it is obvious it is a clickable link? Change color, underline, or whatever?

So instead of

Col 1           Col 2         Col 3
Data            Data          Data
Data            Data          Data

I would have

Col 1           Col 2         Col 3
Data            Data          Data
Data            Data          Data

Or the cell text could be underlined.

Please note the grid is populated by a dynamic search at runtime, a datatable is built and bound to the grid.

John.

3 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 02 Aug 2010, 06:52 AM
Hello,

Set the ItemStyle for the corresponding column in order to customize the appearance.

aspx:
<telerik:GridBoundColumn DataField="CustomerID" HeaderText="CustomerID" SortExpression="CustomerID"
    UniqueName="CustomerID">
    <ItemStyle Font-Names="Verdana" Font-Underline="true" />
</telerik:GridBoundColumn>



-Shinu.
0
John
Top achievements
Rank 1
answered on 02 Aug 2010, 03:08 PM
Hi:

Thanks for your reply, but unfortuantely as I mentioned in my note I do not have bound data columns. The columns to appear in the grid are determined by user selections at runtime, so I need some way of setting the text style on just one cell in each row...

John.
0
Pavlina
Telerik team
answered on 05 Aug 2010, 10:21 AM
Hello John,

You can modify the grid cells in ItemDataBound/ItemCreated event. For more information how to achieve your goal, please review the following help article:
http://www.telerik.com/help/aspnet-ajax/grdaccessingcellsandrows.html

All the best,
Pavlina
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Grid
Asked by
John
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
John
Top achievements
Rank 1
Pavlina
Telerik team
Share this question
or