There is a XamCombo Editor.In this there are four drop downs.If I am selecting a value in the first drop down then that value should get disabled in the list for the second drop down and if I am selecting a value in the second drop down then the value selected in the first drop down and the value selected in the second drop down should get disabled for the third drop down and so on.
When I am selecting the value thorough the mouse it is working as expected but in case of keyboard I am facing an issue.
When I am selecting values through the mouse,the values are getting disabled in the drop down and if I am trying to select those values I am unable to do so. But in case of selecting the value through the up and down key of the keyboard the disabled values of the drop down is also getting displayed and are getting selected.I need to avoid the diasbled value selection using the up and down key of the keyboard.
Below is the code snippet:
<infra:XamDataGrid
Name="ssnNameDatagrid" <infra:FieldLayout.Fields>
<infra:Field
Name="SocialSecurityNumber"
Width="Auto"
Label="{Localize socialSecurityNumber}">
<infra:Field.Settings>
<infra:FieldSettings
LabelClickAction="Nothing"
EditorType="{x:Type infraEditor:XamComboEditor}">
<infra:FieldSettings.EditorStyle>
<Style
TargetType="{x:Type infraEditor:XamComboEditor}">
<Setter
Property="ItemsProvider"
Value="{Binding Path=DataContext.ListOfSSNItemsProvider,RelativeSource={RelativeSource Mode=FindAncestor,AncestorLevel=1, AncestorType={x:Type UserControl}} }" />
Property="IsEditable"
Value="True" />
<EventSetter
Event="infraEditor:ValueEditor.ValueChanged"
Handler="OnValueChanged" />
Property="DropDownButtonDisplayMode"
Value="Always" />
Hello Sakshi,
I am just checking if you got this worked out or you still require any assistance or clarification on the matter.
Hello Stefan,
Can you please provide me the complete code the xaml code and the cs file code.
Do you mean the source code of the XamComboEditor?
Looking forward for your reply.
I mean the code for the editor along with the xaml file.The details you gave were of the xaml file and by that the code which was used to implement this functionality was not clear.
I created a sample project, which you can use as basis for any further development. Basically every time you want to use some of the XamComboEditors, you should open and close its dropdown, so the items can be updated.
Hope this helps.