This is a migrated thread and some comments may be shown as answers.

DateTime filter will clear by text filter

1 Answer 57 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Pam Redrum
Top achievements
Rank 1
Pam Redrum asked on 26 May 2010, 03:15 AM
<telerik:RadGrid ID="RGDataMain" runat="server" AutoGenerateColumns="False" AllowFilteringByColumn="True" AllowPaging="True" AllowSorting="True" DataSourceID="LDSDataTransaction" PagerStyle-AlwaysVisible="true" GridLines="None" Skin="Default"
            <PagerStyle AlwaysVisible="True" /> 
            <MasterTableView AllowFilteringByColumn="true" AllowPaging="true" AllowSorting="true" AutoGenerateColumns="false" EnableColumnsViewState="false"
                <Columns> 
                    <telerik:GridDateTimeColumn DataField="DatePurchased" HeaderText="DatePurchased" ItemStyle-Width="139px" FilterControlWidth="139px" DataType="System.DateTime"
                    </telerik:GridDateTimeColumn> 
                    <telerik:GridBoundColumn DataField="Title" HeaderText="Title" ShowFilterIcon="false" CurrentFilterFunction="Contains" FilterDelay="2000"
                    </telerik:GridBoundColumn> 
                    <telerik:GridBoundColumn DataField="FormatName" HeaderText="Format" ShowFilterIcon="false" CurrentFilterFunction="Contains" FilterDelay="2000"
                    </telerik:GridBoundColumn>                     
                    <telerik:GridBoundColumn DataField="RightsOrgName" HeaderText="RightsOrg" ShowFilterIcon="false" CurrentFilterFunction="Contains" FilterDelay="2000"
                    </telerik:GridBoundColumn> 
                </Columns> 
            </MasterTableView> 
        </telerik:RadGrid> 

I have use a RadGrid like this, but when you choose a datetime filter on DatePurchased field, it works right. And then you type something in Title and wait for a short time (make the filter works), the Title filtered, but the DatePurchased 's filter goes to NoFilter.
If you use Title first then DatePurchased  It will be OK too.
Any one have some ideas on this?

1 Answer, 1 is accepted

Sort by
0
Accepted
Shinu
Top achievements
Rank 2
answered on 26 May 2010, 01:21 PM
Hello Pam,

 Set the MasterTableView -> EnableColumnsViewState property to keep the columns settings in the ViewState, which in turn persist the filter text on postback. Hope this information helps you.

Regards,
Shinu.
Tags
Grid
Asked by
Pam Redrum
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or