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. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Selecting Todays date in the edit forms datePicker displays yesterdays date in the e-grid

Thread ID:

Created:

Updated:

Platform:

Replies:

145331 Jun 18,2019 02:24 AM UTC Jun 19,2019 04:34 AM UTC ASP.NET Core - EJ 2 3
loading
Tags: DataGrid
Basil Buwalda
Asked On June 18, 2019 02:24 AM UTC

Hi

I need help with using dates in the e-grid and e-grids edit forms.

There seems to be a problem with selecting Today's date in the e-grids edit forms datePicker where the date is then displayed as yesterdays date in the e-grid.

Quite hard to replicate as I think its got to do with the time.

It might be useful just to demo implementing a date picker in the demo grid

https://ej2.syncfusion.com/aspnetcore/Grid/GridOverview#/material 

Regards


Pavithra Subramaniyam [Syncfusion]
Replied On June 18, 2019 09:27 AM UTC

Hi Basil, 
 
Thanks for contacting Syncfusion support. 
 
We have validated the provided information and we suspect that in your application you are using remote data. By default, while using remote data it send(response) the date value in UTC format and it does not converted to local time zone so we request you to apply the serverTimezoneOffset as below to resolve the reported problem. 

<script> 
    ej.data.DataUtil.serverTimezoneOffset = new Date().getTimezoneOffset() / 60);   //Set the servertimezoneoffset 
</script> 
 
<ejs-grid id="Grid" allowPaging="true" toolbar="@( new List<object>() {"Add","Edit","Delete","Update","Cancel"})"> 
    <e-grid-editSettings allowAdding="true" allowDeleting="true" allowEditing="true"></e-grid-editSettings> 
    <e-grid-columns> 
        <e-grid-column field="OrderID" headerText="Order ID" isPrimaryKey="true" textAlign="Right" width="100"></e-grid-column> 
        . . . .  
    </e-grid-columns> 
</ejs-grid> 

If you still facing the sample problem then share code example or sample with data which will be more helpful for us to validate further and to provide a better solution as soon as possible. 
 
Regards, 
Pavithra S. 


Basil Buwalda
Replied On June 18, 2019 09:12 PM UTC

Thank s for you super quick reply

Pavithra Subramaniyam [Syncfusion]
Replied On June 19, 2019 04:34 AM UTC

Hi Basil,  

Thanks for your update. 

Please contact us if you need any further assistance. As always, we will be happy to assist you.  

Regards,  
Pavithra S. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon