Prepopulate / Set date

3 posts, 0 answers
  1. Madzie
    Madzie avatar
    65 posts
    Member since:
    Apr 2012

    Posted 17 Nov 2013 Link to this post

    How to set date to today + 1 month i.e if today is
    11/12/2013, then set to 12/12/2013 using knockout-kendo

    Like the today's date is set as below
          self.todaysDate = ko.observable(new Date());
    how to set this one based on todaysDate
          self.nextDate = ko.observable(?????);


  2. Alexander Valchev
    Admin
    Alexander Valchev avatar
    2875 posts

    Posted 18 Nov 2013 Link to this post

    Hi Madzie,

    If I understood correctly, the question is now to calculate the today + 1 month day. The answer is:
    var date = new Date();
    date.setMonth(date.getMonth() + 1);

    On a side note, I would like to remind you that this question is not directly related to Kendo UI and as such is out of the scope of our support service. The knockout library, as well as knockout-kendo framework are not developed nor maintained by the Kendo UI Team. Any support requests (via tickets or forum posts) should go to either StackOverflow, or to the issues list for that project.

    Regards,
    Alexander Valchev
    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. Madzie
    Madzie avatar
    65 posts
    Member since:
    Apr 2012

    Posted 18 Nov 2013 Link to this post

    Thanks Alexander. I do post it there too, just to make sure I get the answer ASAP !
    But I shall keep in mind in future.
Back to Top