i created an usercontrol for datagridview.
I set it as gridview.autoGeneratecolumn = false; in the usercontrol.
Question: How do i add columns to the usercontrol in my UI form?
-
I cannot add default columns to the usercontrol as other UI form might not using the same columns.
-
If i do not put
gridview.autoGeneratecolumn = false;, then the auto generated columns will be showing my database columns name instead of the name i want to display to the user.
Extending on the property above
You can then loop through the ColumnList and Add and also set the basic properties for the columns