Home Forums WinForms controls Xceed Grid for WinForms May I add a label or button column as sepator? Reply To: May I add a label or button column as sepator?

User (Old forums)
Member
Post count: 23064

I’m trying the above mentioned code but I’ getting a System.InvalidOperation Exception “An attempt was made to add an uninitialized column to a ColumnList”

here’s my code:
Xceed.Grid.Column colSeparator = new Xceed.Grid.Column();
colSeparator.CanBeGrouped = false;
colSeparator.CanBeSorted = false;
colSeparator.Width = 22;
colSeparator.MinWidth = 12;
colSeparator.MaxWidth = 22;
colSeparator.Title = ” “;
DFGrid.Columns.Insert(1, colSeparator);

TIA

Imported from legacy forums. Posted by beny (had 316 views)