WeekdayName - Built-in Date & Time Function¶
Purpose¶
WeekdayName returns the name of the day of the week from a datetime expression.
Syntax¶
WeekDayName(datetime [, bool])
Arguments¶
| Argument | Required | Description |
|---|---|---|
datetime |
Yes | Any valid datetime expression from which the weekday will be returned |
bool |
No | When a true value is passed, the abbreviated name of the weekday is returned (e.g. "mo" instead of "Monday") |
Returns¶
String
See also¶
- Date
- DateAdd
- DateDiff
- DatePart
- DateValue
- DateSerial
- Day
- Hour
- InAgedToDays
- InLast4WeeksToSunday
- InLast7Days
- InLastFullMonth
- InLastFullWeek
- InLastYearMTD
- InLastYearYTD
- InLeapYear
- Minute
- Month
- MonthName
- Now
- Second
- Time
- TimeSerial
- TimeValue
- WeekAgo
- Weekday
- Year
Example¶
// returns "Friday" when PC’s regional settings are set to English
Return WeekDayName(DateSerial(2014,5,30))
Notes¶
- When
datetimecannot be converted to a datetime value, a runtime error is generated. - WeekdayName uses the locale settings to return the name of the day of the week.