Home Search

DriveWorks Pro 22
Weekday

Send Feedback

WeekDay

This function returns a number representing the day of the week.

Syntax

WeekDay([Date],[Return Type])

Where:

Date is the date to return the weekday from

Return Type is a number representing the day in which the week starts

Return Type

Number returned
1 or Omitted Numbers 1 (Sunday) through 7 (Saturday)
2Numbers 1 (Monday) through 7 (Sunday)
3Numbers 0 (Monday) through 6 (Sunday)
11Numbers 1 (Monday) through 7 (Sunday)
12Numbers 1 (Tuesday) through 7 (Monday)
13Numbers 1 (Wednesday) through 7 (Tuesday)
14Numbers 1 (Thursday) through 7 (Wednesday)
15Numbers 1 (Friday) through 7 (Thursday)
16Numbers 1 (Saturday) through 7 (Friday)
17Numbers 1 (Sunday) through 7 (Saturday)

Examples

Rule

Meaning
WeekDay(Today(),2)If this function is called on a Monday it will return 1 as the return type is set to start counting Monday as the first day (2)
WeekDay("10/08/2010")This will return 6 as the date given falls on a Friday and the return type omitted which will start counting Sunday as the first day.

DriveWorks Tech Tips Portal

Date Picker

This project shows how to use the date functionality within DriveWorks, taking things such as leap years into account.

View all Tech Tips

DriveWorks Tech Tips Portal is available to DriveWorks Pro customers with an active subscription and support contract.

Tech Tips provide cut down projects that highlight specific functionality for faster and more effective learning.

To access the portal:

  1. Go to https://my.driveworks.co.uk/learn/tech-tips/
  2. Login with your DriveWorks Pro account credentials, if asked
  3. Click the Visit Tech Tips Portal button for access

The portal provides a search facility, start typing the name of the Tech Tip (as indicated above) to display the Tip you require.