@Month (Formula Language)
Extracts the number of the month from the specified time-date.
Syntax
@Month( time-date )
Parameters
time-date
Time-date or time-date list. The value with the month that you want to extract.
Return value
month
Number or number list. The number of the month. Returns -1 if the time-date provided contains only a time value and not a date.
Usage
If the parameter is a list, the function operates on each element of the list, and the return value is a list with the same number of elements.
Examples
- This example returns 1.
@Month([1/15/88])
- This example returns 1 and 2 in a list.
@Month([1/15/88] : [2/15/88])
- This example returns 12 if it is December.
@Month(@Now)
- This example returns 2 if it is any date in December other than
the 30th or the 31st. If it is December 30th or 31st, returns 3.
@Month(@Adjust(@Now;2;2;2;2;2;2))
- This formula returns a formatted date string based on the contents
of the dueDate field. For example, if dueDate contains "06/26/95"
the formula returns June 26, 1995. If dueDate contains "01/24/96 3:40:43
P.M.," the formula returns January 24, 1996.
space:= " "; comma:=","; month:=@Select(@Month(dueDate);"January";"February";"March"; "April";"May";"June";"July";"August";"September";"October"; "November";"December"); day:=@Text(@Day(dueDate)); year:=@Text(@Year(dueDate)); month + space + day + comma + space + year