I have created a RadGrid. Here is the steps I used to create it and then remove all the rows (I just want the header - details why below)
I clear the rows in the datatable that I bind to the grid
I set the RadGrid datasource = to that blank datatable
I then bind
I also set the NoDetailRecordsText = "" and NoMasterRecordsText = ""
I have column headers that are dates (1/12 for example) and each day they change. Those are in the middle of the columns. All the other columns have named headers I know about (except the dates)
Column layout
Hardware Model 1/2 1/3 1/4 Col1 Col2 etc.
I need to set all the columns to a value (only way i know to set those date ones but code I have tried does not work) in ItemCreated event
For Each col As GridColumn In grdHeader.MasterTableView.Columns
col.HeaderStyle.Width = "60" 'Never gets to this
Next
then go and set the rest of the column widths (this seems to work)
Dim gridCol As GridColumn
gridCol = grdHeader.MasterTableView.GetColumn("Model")
gridCol.HeaderStyle.Width = "140"
The reason I need to do this is we have scrolling RadGrids per group and I want to keep the header above the scrolling section as when it scrolls each header for each grid goes away and you have no clue what cols go with what data.
I hope this give enough to hopefully point me in the right direction.
I appreciate any help