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

[Solved] RADGrid: Column Formatting

1 Answer 121 Views
Grid
This is a migrated thread and some comments may be shown as answers.
G
Top achievements
Rank 1
G asked on 07 May 2009, 06:17 PM
Hi,

I have a radGrid that displays sections for a website (part of a CMS system), the system allows the user to adjust the order of the sections, by clicking on an up or down arrow in 2 GridButtonColumns, all is working fine, however this is what I want to do.

I don't want the up arrow displayed on the first row and I don't want to display the down arrow on the last record, for obvious reasons (the first record can go UP any further in the order and vice versa with the last).

The solution to this is probably easy, but my brain has failed in the thinking process.

1 Answer, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 11 May 2009, 08:55 AM
Hello,

You can use the RadGrid PreRender event to access the table cells from the first and last table rows and remove the unwanted buttons:

http://www.telerik.com/help/aspnet-ajax/grdaccessingcellsandrows.html

You can get all the data items in PreRender by using RadGridInstance.MasterTableView.Items :

http://www.telerik.com/help/aspnet-ajax/telerik.web.ui-telerik.web.ui.gridtableview-items.html

Best wishes,
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.
Tags
Grid
Asked by
G
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Share this question
or