In this tutorial, I will show you some useful property settings of Oracle Apex Date Picker item.
I am going to use the properties shown in the below image so that when I will give the reference below of any property you can see it in the image.
1. Highlighting another Date with Current Date
In Oracle Apex date picker the current date is highlighted and focused by default, but if there is a requirement to highlight and set focus to a particular date, then use the following settings for the
Highlighted Date property:
For example, highlight the date after the 7th day of the current date.
- Highlighted Date:
Today is the 4th April 2020, so after adding the 7 more days the date 11th April is also highlighted.
Similarly, if you want to highlight a day before the current date use hyphen (-), for example:
-7d to highlight a date 7 day before the current date.
The basic syntax of specifying the date values are:
+1w to highlight the date before or after 1 week of the current date.
+2m to highlight and focus a date after two months of the current date.
Also, you can specify a page item having a valid date value to highlight the particular date. For example,
2. Setting a Minimum and Maximum Date
The same rules apply to the
Maximum Date settings. The following are the examples:
Setting a minimum date to the current date and maximum date to 2 weeks later the current date.
- Minimum Date:
- Maximum Date:
You can notice in the above image, that all other dates are disabled and only the current date with dates 2 weeks later is enabled.
Maximum property settings, you can also specify the page item having the valid date value.
3. Display Drop Down for the Month and Year
To display the drop-down list for
Year to access it easily, set the following property:
- Navigation List for: Month or (Month and Year)
4. Display the Hours and Minutes Drop Down
To display the hours and minutes drop-down in the date picker item use for
Format Mask property to specify the time format:
- Format Mask: