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
2090
XamDataGrid with ComboBoxField: Disable userinput, allow only selection
posted

Hello,

a XamDatagrid uses a ComboBox to offer a selection. How can I disable the userinput and allow only the selected of the databound items? It should work like the standard WPF Combobox.

                    <igDP:ComboBoxField Name="Aktion" IsEditable="True" >
                        <igDP:Field.Settings>
                            <igDP:FieldSettings EditorType="{x:Type igEditors:XamComboEditor}" DataItemUpdateTrigger="OnCellValueChange">
                                <igDP:FieldSettings.EditorStyle>
                                    <Style TargetType="igEditors:XamComboEditor">
                                        <Setter Property="ItemsSource" Value="{Binding Path=Data.Aktionen, Source={StaticResource Proxy}}" />
                                    </Style>
                                </igDP:FieldSettings.EditorStyle>
                            </igDP:FieldSettings>
                        </igDP:Field.Settings>
                    </igDP:ComboBoxField>

Thanks

Niko

  • 34690
    Offline posted

    Hello Niko,

    In order to disable the user input and allow only selection in the drop-down in the ComboBoxField, simply set the IsEditable property of the ComboBoxField to false. This will still allow selection in the drop-down while disallowing the ability to type in the combo.

    Please let me know if you have any other questions or concerns on this matter.