jQuery UI Widgets Forums Editors DateTimeInput Restrict DatePicker Navigation

This topic contains 1 reply, has 2 voices, and was last updated by  George Todorov 8 years, 3 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Restrict DatePicker Navigation #1073

    ijekov
    Member

    I have 2 questions about the DateTimeInput.

    1. How to restrict the possible navigation dates?

    2. Can I make the input field readonly? I want input only from the calendar.

    Thanks in advance

    Restrict DatePicker Navigation #1098

    Hi ijekov,

    Thank you for writing.

    Regarding your questions:

    1. To restrict the range of allowed dates, you can use the “setMinDate” and “setMaxDate” functions.

    For example:

    $("#jqxDateTimeInput").jqxDateTimeInput('setMinDate', new Date(2010, 0, 1));
    $("#jqxDateTimeInput").jqxDateTimeInput('setMaxDate', new Date(2013, 0, 1));

    2. You can achieve this by setting the ‘readonly’ property to true. The code example below shows how to set it:

    $("#jqxDateTimeInput").jqxDateTimeInput('readonly', true);

    Best Regards,
    George

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.