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

Filter Date Column as String

1 Answer 23 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Laurie
Top achievements
Rank 2
Laurie asked on 15 Sep 2010, 05:27 PM
I'm trying to use autopostbackonfilter to enable the users to enter a date or date fragment and have the filter return all records that contain that date fragment.  This is my code:

 

 

<telerik:GridBoundColumn DataField="InvitedOn" HeaderText="First Invited On" UniqueName="InvitedOn" AutoPostBackOnFilter="true">
</telerik:GridBoundColumn>


It works just fine when the user enters the date or date fragment, but if the user enters text that is not in date format, e.g. "ddd" or "9/15/20100," it returns all records.  I would expect it to return no records in these cases.  How can I get the expected behavior?

Thanks!

Laurie 

 

1 Answer, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 21 Sep 2010, 10:06 AM
Hello Laurie,

To achieve your goal, please consider using built-in GridDateTimeColumn as shown in this online demo.
Dive this suggestion a try and let me know how it goes.

All the best,
Pavlina
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Grid
Asked by
Laurie
Top achievements
Rank 2
Answers by
Pavlina
Telerik team
Share this question
or