We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Grid locale not applied to datepicker control column?

I set my grid to hr-HR locale but when open datepicker control in the editor, there is not hr-HR locale for it.





How to set the locale for the grid datepicker edit control?

Thanks!
Bernard.

5 Replies

TS Thavasianand Sankaranarayanan Syncfusion Team July 22, 2019 07:25 AM UTC

Hi Bernard, 

Thanks for contacting Syncfusion support. 

we have validated your requirement. You can set the locale for the datepicker  control by using the editParams. 
Please find the below code snippet and documentation link for more information. 


@{ 
    var editParams = new { @params = new { locale = "hr-HR" } }; 
                <e-grid-column field="OrderDate" headerText="Order Date" editType="datepickeredit" edit=editParams format="yMd" width="170"></e-grid-column> 


                             https://ej2.syncfusion.com/documentation/api/datepicker#locale 

Please get back to us, if you need further assistance. 

Regards, 
Thavasianand S. 



BJ Bernard Jurlina July 22, 2019 06:15 PM UTC

Hi S,

and thanks for the answer. This is what I have in my _Layout.cshtml file



and when I put the editParams like you said



I get this error: