Hi, everyone.
I create a project with the simple grid. But when I trying to set a filter using the Custom Filter Dialog, I am not able to input any value. Could you please help me with that?
Image Example
Hello Gleb,
Thank you for contacting Infragistics. In order to edit the Custom Filter Dialog you will be required to implement a FilterItemTemplate and FilterEditorTemplate for each TemplateColumn.
eg.
<ig:TemplateColumn Key="String"> <ig:TemplateColumn.ItemTemplate> <DataTemplate> <TextBlock Text="{Binding String, Mode=TwoWay, UpdateSourceTrigger=Explicit}"/> </DataTemplate> </ig:TemplateColumn.ItemTemplate> <!--<ig:TemplateColumn.EditorTemplate> <DataTemplate> <StackPanel Orientation="Vertical"> <TextBox Text="{Binding Category, Mode=TwoWay}" Height="25" /> </StackPanel> </DataTemplate> </ig:TemplateColumn.EditorTemplate>--> <ig:TemplateColumn.FilterItemTemplate> <DataTemplate> <StackPanel Orientation="Vertical"> <TextBlock Text="{Binding Value}" Height="25" /> </StackPanel> </DataTemplate> </ig:TemplateColumn.FilterItemTemplate> <ig:TemplateColumn.FilterEditorTemplate> <DataTemplate> <StackPanel Orientation="Vertical"> <TextBox Text="{Binding Value}" Height="25" /> </StackPanel> </DataTemplate> </ig:TemplateColumn.FilterEditorTemplate></ig:TemplateColumn>
Let me know if you have any questions.
Nice, Thank you.
But could I use some default templates for it if I know which type should be in the filter (i mean text, numeric, dates)?
Because I wouldn't like to create a validation for this dialog to check some input values.
If not, could you help me with validation for this dialog? Also, Have I able to prevent closing this dialog if a user typed any invalid values?
This was previously discussed on the following thread:https://www.infragistics.com/community/forums/t/35200.aspx
The dialog uses an embedded xamdatagrid that cannot be modified from the instance your have.
There are two options:
1. Override the default style for DataPresenterGeneric.
2. Create your own dialog with custom editors that have their own validation.
Got it, thanks.