Hello:
One of my Infragisitcs combo boxes needs separators between items. Something like:
"GroupA", Item 1, Item 2,
"Group B", Item10, Item 11, Item 12, Item 13,
"Group C", Item 20, Item 21, Item 22,
etc.
Combo Box is DB to a list, I know I can insert the items in the list, question is how to make them not selectable? Is there way to have the groups labels formatted with a different font (like bold)?
Thanks,
Mihail
That's it, SIMPLE, I was looking for disable at the cell level not the row!
thanks,
Hello,
You could prevent selection of a row of UltraCombo if you handle InitializeRow event and disabled the desired row with following code:
if (e.Row.Index == 0)
e.Row.Activation = Infragistics.Win.UltraWinGrid.Activation.Disabled;
Please let me know if you have any further questions.
I was able to add my group separators and set their font to bold in:
private void _gridHeadersSmartCombo_InitializeRow(object sender, InitializeRowEventArgs e)
e.Row.Cells[3].Appearance.FontData.Bold = DefaultableBoolean.True;
Is there a way to set the whole row non selectable somehow? I tried "Selected" doesn't work, nothing to set this row disabled, unselected? I just don't want to have the groups separators selectable.
Not selectable - I mean not be able to click on it and select the item. The only selectable items should be only the one listed after the label - "Group 1" can't select Item1, Item 2, Item 3 can select. The combo is bind to a list so I can insert these group values in the list. Do you have an example for something like this?
Thanks, Mihail
UltraComboEditor has ability to select multiple values, for more information please see following link:
http://help.infragistics.com/Help/NetAdvantage/WinForms/2011.1/CLR2.0/html/WinComboEditor_Selecting_Multiple_Values_within_WinComboEditor.html
Also you could set different appearance for each ValueListItem via its Appearance property. Please review the list of ValueListItem class members:
http://help.infragistics.com/Help/NetAdvantage/WinForms/2011.1/CLR2.0/html/Infragistics2.Win.v11.1~Infragistics.Win.ValueListItem_members.html
Could you please explain what you mean with “not selectable”, please give me more details about your goal.