This is a migrated thread and some comments may be shown as answers.

Kendo Scheduler Datasource date format

1 Answer 271 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
Markus asked on 10 Feb 2015, 02:26 PM

I am loading (trying to) data from my db for the scheduler.

I cannot find any documentation of how the date format should arrive from the database to be displayed properly.

In above example the Date() function is used like this:

dataSource: [
      id: 1,
      start: new Date("2013/6/6 08:00 AM"),
      end: new Date("2013/6/6 09:00 AM"),
      title: "Interview"

I do now want to create data on the fly so how to format the date so Kendo Scheduler understands? Preferably YYYYMMddhhmmss - 20130606142023

I have also seen that in some of your examples you plug in data with date strings like this:

    "Start": "/Date(1370847600000)/",
    "End": "/Date(1370851200000)/",

Those appear on the 10th of June but I cannot figure out how?


1 Answer, 1 is accepted

Sort by
Alexander Popov
Telerik team
answered on 12 Feb 2015, 11:37 AM
Hello Markus,

There is no exact format that one should follow. The DataSource's schema.model option allows custom parse function to be specified, which can parse the incoming strings using the parseDate method. The same can be achieved using the schema.parse option as well, however it works on all fields instead on just a specific one.

Alexander Popov
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Asked by
Top achievements
Rank 1
Answers by
Alexander Popov
Telerik team
Share this question