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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Format date coming back 'Date(1365715800000)' as MM/dd/yyyy

Thread ID:

Created:

Updated:

Platform:

Replies:

141352 Dec 6,2018 09:13 PM UTC Dec 7,2018 04:44 AM UTC ASP.NET MVC - EJ 2 1
loading
Tags: Grid
Kyle Crabtree
Asked On December 6, 2018 09:13 PM UTC

When I get data back from server side in JSON format, the date is formatted similar to 'Date(1365715800000)'.  How can I format the grid to not display it that way?

Grid issue

https://imgur.com/a/ussXYEE

Madhu Sudhanan P [Syncfusion]
Replied On December 7, 2018 04:44 AM UTC

Hi Crabtree, 

Thanks for contacting Syncfusion support. 

From the image we suspect that you are assigning the dataSource to the grid externally at the client side. If so please parse the data using our parseJson method as follow to convert the server string to date objects. 


  <script> 
    var grid = document.getElementById('Grid').ej2_instances[0] 
    grid.dataSource = ej.data.DataUtil.parse.parseJson(data) 
  </script> 



If you are still facing this problem then please share us the grid rendering code and screenshot of the network tab to check request and response data. 

Regards, 
Madhu Sudhanan P 


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

;