Tech Tip: TimePicker widget can only be modified if placed on page 0 or 1 of the form
PRODUCT: 4D | VERSION: 15.1 | PLATFORM: Mac & Win
Published On: March 25, 2016
The Timepicker widget is a pre-formated object in the object library that allows users to quickly input time through a drop down list.

The object comes with the following code:
By default, the min time available is 8:00 AM, while the max time available is 8:00 PM with 15 minute steps in between.
These parameters can be modified by setting the variable $Customise to true. Please note that the widget modifications take effect if the widget is placed on page 0 or 1 of the form

The object comes with the following code:
Case of : (Form event=On Load) // declare the variable here or anywhere else in your own code C_TIME(vTime) // then if needed, customize the time picker // default values are Min = 8:00 Max = 20:00 Step = 0:15 // All exemples below are inactivated (if false) C_BOOLEAN($Customise) $Customise:=False If ($Customise) //use current object (if you don't the methods will change default values of time pickers) $ObjectName:=OBJECT Get name(Object current) TimePicker SET MIN TIME ($ObjectName;?10:00:00?) TimePicker SET MAX TIME ($ObjectName;?16:00:00?) TimePicker SET STEP ($ObjectName;?00:20:00?) End if End case |
By default, the min time available is 8:00 AM, while the max time available is 8:00 PM with 15 minute steps in between.
These parameters can be modified by setting the variable $Customise to true. Please note that the widget modifications take effect if the widget is placed on page 0 or 1 of the form