Nov-29-2018, 12:22 PM
From a JSON file, I'm getting this type of date "/Date(158889600000)/" and I would like to convert this string to a date type.
Does anyone know how I can do that?
Does anyone know how I can do that?
Date format conversion "/Date(158889600000)/"
|
Nov-29-2018, 12:22 PM
From a JSON file, I'm getting this type of date "/Date(158889600000)/" and I would like to convert this string to a date type.
Does anyone know how I can do that?
Nov-29-2018, 02:11 PM
Not really. I mean, it's not clear what date that is. Even knowing what date it is might not be enough. A common way to store a date or time is as a number of time units (days or seconds, usually) since a particular point in time. But that starting point in time can be different depending on what system generated the number. I would look back to where you got the JSON data from, and see if they describe how the date is defined.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness. Recommended Tutorials: BBCode, functions, classes, text adventures
Nov-29-2018, 02:14 PM
That number is greater than that emitted by timt.time
I suspect it is formatted in some way. Need more information. can you post the code, or point to where it can be looked at? There's just not enough information here. |
|