Hi,
I am blocked at xamdatagrid validation for 2 days now. I have exercised your forum's answers but none of them helped me.
I am using a xamcomboeditor on a field, and setting itemsprovider via style using:
<igEditors:ComboBoxItemsProvider x:Key="ComboItemsProvider" ItemsSource="{Binding Path=ListOfModels, Source={StaticResource viewModel}}" DisplayMemberPath="Name" ValuePath="Id"/>
Problem is that, now if I want to use Clipboard operations, ("ALL"), this cell is accepting anything. Not checking if the item being pasted is available in the list of items.
FYI: I have tried using this:
<Setter Property="ValueConstraint"> <Setter.Value> <igEditors:ValueConstraint Enumeration="{Binding Source={StaticResource ComboItemsProvider}}"/> </Setter.Value> </Setter>
seems like enumeration not binding properly.
PS: I have also tried binding this enumeration with another class that has the same list (which is redundant and not right), but it doesnt work even then.
Please help me out.
Hello,
I have created a sample project using the code you have provided and everything seems to work ok on my side. If the sample doesn’t satisfies all your needs feel free to modify it, so it reproduces your behavior and send it back to me for further investigation.
Looking forward for your reply.
Thanks for the reply.I tried this and got validation error (Invalid value) on pasting wrong value but also even when I select any other item from the comboeditor itself.
Thank you for your post. I have been looking into it and I can suggest you set the BindingPath of the ValueConstraint’s Enumeration’s Binding to “ItemsSource” like this:
<Setter Property="ValueConstraint"> <Setter.Value> <igEditors:ValueConstraint Enumeration="{Binding Source={StaticResource ComboItemsProvider},Path=ItemsSource}"/> </Setter.Value> </Setter>
Please let me know if this helps you or you have further questions on this matter.