I started trying your RadControls specifically for the use of the GridView hierarchy, but lately have noticed a lot of complications when trying to make the transition from regular DataGridView to RadGridView. One such example:
I have a RadGridView bound to a table on a SQL Server database. Retrieving the information is fine, however, I want to make some cells hyperlinks. Previously, I would write something like this to change my cells from regular TextBoxCells to HyperlinkCells after the binding completed:
each (Windows::Forms::DataGridViewColumn^ column
each (DataGridViewRow^ row
row->Cells[column->Index] = gcnew DataGridViewLinkCell();
But I notice there isn't any GridViewHyperlinkCell class or anything similar. How would I go about replicating this behavior? The entire column can be HyperLinkCells. I understand that you can make the entire column of type GridViewHyperLinkColumn, but how would I achieve this dynamically?
EDIT: To accomplish the functionality I described above, I did the following:
- Set the GridView property "AutoGenerateColumns" to False
- Manually added columns w/ desired column type and set the "FieldName" property to the corresponding column header name in my database table. This directly reflected the table structure in my database.
- Set the GridView's "DataSource" to the bindingSource I use to retrieve the table from the database.
This takes the ease out of setting and forgetting, but I couldn't figure out an alternate way.