How can you add a value constraint to a a XamMultiColumnComboEditor ? It doesn't implement ValueEditor, so you cant apply as you would with a XamComboEditor...
var style = new Style(typeof(XamComboEditor)); style.Setters.Add(new Setter(ValueEditor.ValueConstraintProperty, constraint)); return new UnboundField { Settings = { EditorType = style.TargetType, EditorStyle = style } };
Is it possible to do similar with a XamMultiColumnComboEditor ?
Cheers
Jonathan
Hi Jonathan,
There are currently two kinds of combo editors in the WPF product. One kind is the XamComboEditor that exists inside the Infragistics.Windows.Editors namespace. This is the editor that derives off of ValueEditor and contains the ValueConstraint property. The other kind is the XamMultiColumnComboEditor and XamComboEditor that exist inside the Infragistics.Controls.Editors namespace. These controls were originally created to support both Silverlight and WPF and are a separate set of controls. These do not derive from ValueEditor so they do not have a ValueConstraint.
What kind of constraint are you trying to implement on XamMultiColumnComboEditor? Maybe there is a different way to implement it other than a ValueConstraint.
We'd ideally like the same behaviour that the XamComboBox has. On the XamComboBox we can give it a...
new ValueConstraint {Nullable = false}
This will then ensure that the combobox has a value and if not it shows a little red asterix and decorates the combobox with a red outline.
if this is achievable some other way it would be great.