I have below code and I want to disable the rows that has IsActive = false.
They shall not be able to click on the disabled records and the combo should not collapsed and select those records.
They only should be able to select the records that are active.
<widgets:MultiColumnDropdownList Name="comboCd"
Margin="0,0,20,5"
ComboWidth="250"
DisplayMemberPath="Code"
DropDownPopupWidth="450"
FieldItemsSource="{Binding CodeList}"
FieldLabel="Codes "
FieldSelectedItem="{BindingSelectedCodeRecord,
Mode=OneWayToSource,
UpdateSourceTrigger=LostFocus}"
LabelAlignment="Left"
LabelPosition="Horizontal"
LabelWidth="95">
<widgets:MultiColumnDropdownList.Columns>
<ig:TextComboColumnKey="Code" HeaderText=" Code " />
<ig:TextComboColumn Key="Description" HeaderText=" Description " />
<ig:TextComboColumn Key="IsActive" Width="0" Visibility="Hidden"/>
</widgets:MultiColumnDropdownList.Columns>
</widgets:MultiColumnDropdownList>
Hello Erol,
Thank you for your post. I have been looking into it and I can suggest you add the following Style for the ComboCellsPanel to your XamGrid’s Resources:
<Style xmlns:igPrim="http://schemas.infragistics.com/xaml/primitives" TargetType="{x:Type igPrim:ComboCellsPanel}"> <Setter Property="IsEnabled" Value="{Binding IsActive}"/> </Style>
This way the Rows that has IsActive Property set to false won’t be able for selection. Please let me know if this helps you or you need further assistance on this matter.
Looking forward for your reply.
Thanks Stefan.
Thank you for your feedback. I am glad that you resolved your issue and I believe that other community members may benefit from this as well.
Thanks again.