Skip to main content

getWidget()

returns the dhtmlxTimePicker widget attached to a TimePicker control

getWidget(): Timepicker;

Returns:

An object of the dhtmlxTimePicker widget.

Example

var timepicker = form.getItem("timepicker").getWidget();  // -> dhtmlxTimePicker

It is possible to use methods of dhtmlxTimePicker via the getWidget() method of a TimePicker control.

For example, you can set value for a TimePicker control. To do this, you need to get the widget attached to the TimePicker control and then use the setValue() method of this widget.

var timepicker = form.getItem("timepicker").getWidget();  // -> TimePickertimepicker.setValue("00:39"); //set the value as a string