FileDescriptor DateTime Format

0 Answers 29 Views
DateTimePicker GridView
Pablo
Top achievements
Rank 1
Pablo asked on 03 Jul 2024, 07:22 PM | edited on 03 Jul 2024, 08:30 PM

Hi!  I am seeking assistance with this column in WPF, in a RadGridView:

<telerik:GridViewDataColumn DataMemberBinding="{Binding TargetDateET, StringFormat={}{0:MM/dd HH:mm}}" Header="Target Date" />

It displays DateTime values in the grid in the following format: "MM/dd HH:mm"

The issue is that the FilterDescriptor is in this format: "MM/dd/yyyy HH:mm:ss tt"

And when the filters are saved and presented to the user, they are different.



What I can do to manage this data in the same format? (Without having to generate a new variable that is a string and that returns the correct format) Help! Thanks in advance! Juan

Dimitar
Telerik team
commented on 04 Jul 2024, 11:29 AM

Hi Pablo, 

The column formatting does not change the underlying data and the DateTime object will remain the same. I do not think there is a way to avoid formatting the DateTime value when presenting it to the user in this case. 

Let me know if you have additional questions.

 

Pablo
Top achievements
Rank 1
commented on 04 Jul 2024, 06:00 PM

Hi Dimitad, thanks for your reply. Is there any way to create a custom filter, a CellTemplate, or something similar to achieve this?
Martin Ivanov
Telerik team
commented on 09 Jul 2024, 08:10 AM

There are different options for customizing the filtering. Can you show me what exactly you need to customize? This way I can think of more specific idea. Also, can you tell me what is this "Filters Applied" visual above the RadGridView. It seems like some custom element.

No answers yet. Maybe you can help?

Tags
DateTimePicker GridView
Asked by
Pablo
Top achievements
Rank 1
Share this question
or