Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
770
Exception adding custom value in a grid
posted


Given this definition:
<ig:XamComboEditor 
x:Name="productCombo" 
ItemsSource
="{Binding Products}" 
SelectedItem
="{Binding Product, Mode=TwoWay, ValidatesOnExceptions=True, NotifyOnValidationError=True, ValidatesOnDataErrors=True, ValidatesOnNotifyDataErrors=True}" 
DisplayMemberPath
="ComboDisplayName" 
HorizontalAlignment
="Stretch" 
Margin
="0" 
VerticalAlignment
="Center" 
AutoComplete
="True" 
CustomValueEnteredAction
="Add" 
DataObjectRequested
="productCombo_DataObjectRequested"/>

I get this exception trying to add an item not currently in 'Products' ie as a consequence of the CustomValueEnteredAction.
A first chance exception of type 'System.Exception' occurred in InfragisticsSL4.Controls.Editors.XamComboEditor.v10.2
System.Exception
Can not create a new data item, when there is no ItemSource set. Please make sure that you have hooked up an ItemSource to the XamWebComboEditor.
   at Infragistics.Controls.Editors.XamComboEditor.CreateItem()
   at Infragistics.Controls.Editors.XamComboEditor.CommitTextAsSelected(Boolean closeDropDown, Boolean cancelSelection, Boolean moveSelectionToTheEnd, Boolean allowUseOfFocusedItem)
   at Infragistics.Controls.Editors.XamComboEditor.Editor_LostFocus(Object sender, RoutedEventArgs e)
   at MS.Internal.CoreInvokeHandler.InvokeEventHandler(Int32 typeIndex, Delegate handlerDelegate, Object sender, Object args)
   at MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, String eventName)
ItemsSource is definitely not null (although the message refers to ItemSource?)

Parents Reply Children