Click to See Complete Forum and Search --> : How SQL DataAdapter can add a custom column to DataGridView?


vojtek11
January 2nd, 2009, 08:10 AM
I'm using DataGridView control and DataAdapter with SQL database does all control over it. Database can be of course on demand updated back with whatever user added/deleted/modified in the DataGridView.

Thing is - when DataAdapter initially fills DataGridView control and creating automatically columns and rows (as they are downloaded from SQL database), I need all columns to be MyCustomTextBoxColumn, not default DataGridTextBoxColumn. Can I do that?

Thanks in advance,
Vojtek

JonnyPoet
January 2nd, 2009, 04:25 PM
Yes you can have custom columns in a datagridview and as much as I know there is a full example for that how to create a custom datagridviewControl ( it has three radiobuttons in one column ) So it also should be possible to bind a datagrid which has a custom textboxcolumn to an sql Datasource.