Radgridview Date Filter Localization

1 Answer 21 Views
GridView Localization
Tomáš
Top achievements
Rank 1
Iron
Tomáš asked on 11 May 2022, 11:38 AM

Hello,

I'd like to translate parts of the date filter in the radgridview - see the pic (numbers 1, 2, 3 are in order of clicks to get to the specific filter settings).

Those red rectangles need to be translated. And the date format should be in a short form (like 11.05.2022).

How to do that? It seems it has to do something with a FilterPopupInitialized event but I don't know what to do there.

Thanks in advance.

Regards,

Tomáš

1 Answer, 1 is accepted

Sort by
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 11 May 2022, 12:30 PM

Hello, Tomáš,

Usually RadGridView offers localizing the strings in the control by implementing a RadGridLocalizationProvider. Please refer to the following help article: https://docs.telerik.com/devtools/winforms/controls/gridview/localization/localization

However, RadGridView uses a RadDataFilter control to allow building of custom filtering expressions. The strings used by the data filter control can be customized after inheriting the DataFilterLocalizationProvider class: RadDataFilter Localization

As to the date format, it depends on the specified format for the column: 

            GridViewDateTimeColumn dateColumn = this.radGridView1.Columns["OrderDate"] as GridViewDateTimeColumn;
            dateColumn.Format = DateTimePickerFormat.Custom;
            dateColumn.CustomFormat = "dd-MM-yyyy";
            dateColumn.FormatString = "{0:dd-MM-yyyy}";

I hope this information helps. If you need any further assistance please don't hesitate to contact me. 

Regards,
Dess | Tech Support Engineer, Principal
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tomáš
Top achievements
Rank 1
Iron
commented on 16 May 2022, 08:24 AM

Hello, Dess,

it was helpful, as always.

Thanks

Regards,

Tomáš

Tags
GridView Localization
Asked by
Tomáš
Top achievements
Rank 1
Iron
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or