Skip to Content

Set Time in DateTimePicker

I use DateTimePicker in my application. The time picker by default shows the system time.

In the above image, the time that I've set using setDateValue / setValue appears correctly in the input field, but the time picker still begins from the system time. How do I make it begin from the time that I specify?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Oct 27, 2017 at 07:21 AM

    Hi,

    You can try that:

    new sap.m.DateTimePicker("DTP4", { dateValue: new Date(2016, 1, 16, 12, 50, 30), displayFormat: "yyyy-MM-dd, HH:mm:ss", editable: false, change: handleChange })

    Regards

    Add comment
    10|10000 characters needed characters exceeded