'getTimezoneOffset' of null

7 posts, 0 answers
  1. jon
    jon avatar
    9 posts
    Member since:
    Jun 2010

    Posted 02 Oct 2014 Link to this post

    Whilst trying to create a scheduler event, i am getting the following error:
    Uncaught TypeError: Cannot read property 'getTimezoneOffset' of null.
    From another post, the suggestion was made to use DateTime2(7) for both the Start and End Dates. I have that and the error still happening.
    The actual event does get saved, but the event form stays open and i have to refresh the screen. All very messy. Any help would be appreciated.


  2. Georgi Krustev
    Admin
    Georgi Krustev avatar
    3707 posts

    Posted 06 Oct 2014 Link to this post

    Hi jon,

    In general, the start and end values of the event are required. Could you verify whether the serialized events have start and end values? If you are receiving this error most probably some of the fields in question is null. If the problem still persists I would ask you to send us a simple test project, which replicates the problem. This will help us to narrow the problem down and advice you further.

    Regards,
    Georgi Krustev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Kendo UI is VS 2017 Ready
  4. M Aslam
    M Aslam avatar
    1 posts
    Member since:
    Dec 2015

    Posted 03 Jan in reply to Georgi Krustev Link to this post

    is there any solution to this issue?
  5. Georgi Krustev
    Admin
    Georgi Krustev avatar
    3707 posts

    Posted 06 Jan Link to this post

    Hello M Aslam,

    If the start/end dates are not parsed correctly, which depends on your schema.model configuration, then the widget will throw the aforementioned error. Basically, you will need to ensure that the widget is setup correctly.

    Regards,
    Georgi Krustev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  6. Andrew
    Andrew avatar
    21 posts
    Member since:
    Dec 2015

    Posted 15 Feb Link to this post

    Still no acceptable answer?

    I am experiencing the exact same error. I have defined:

    start: {
                                type: "date",
                                from: "start_time"
                            },
                            end: {
                                type: "date",
                                from: "end_time"
                            },

     

    Additionally I confirmed with a database browser there are no meetings with start_time or end_time as undefined, null, or an empty string, or even any type other than Date(). Everything on the calendar works, but when I hit the save button KendoUI complains about getTimezoneOffset of null, pointing only to minified files, and the page must be reloaded. The meeting does save, however.

     

    All other CRUD endpoints are hooked up and work correctly. Even a decent workaround would be acceptable.

    I won't get my hopes up though, since this question has been open since October of 2014.

  7. Georgi Krustev
    Admin
    Georgi Krustev avatar
    3707 posts

    Posted 17 Feb Link to this post

    Hello Andrew,

    As I mentioned in my previous reply, the most common reason for the "getTimezoneOffset of null" error is incorrectly passed/set date values.

    I would not be able to continue with the investigation, and hence to answer the questions, without sending us a repro demo. That being said, please send a simplified repro demo that demonstrates the issue. Thus we will be able to debug the code and find the cause of the issue.

    Regards,
    Georgi Krustev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  8. Andrew
    Andrew avatar
    21 posts
    Member since:
    Dec 2015

    Posted 22 Feb Link to this post

    I fixed this issue by forcing my date fields to dates with the new Date(date) syntax in the parse function.

     

     

Back to Top
Kendo UI is VS 2017 Ready