Returns the day from a given date (Integer).

dateThe date you want the day from (Variant).

* The "date" can be any date, text string, numerical expression or any combination.
* If "date" is Null, then Null is returned.
* You can use the DATE function to return the current system date.
* You can use the MONTH function to return the month from a given date.
* You can use the YEAR function to return the year from a given date.
* The equivalent .NET function is Microsoft.VisualBasic.DateAndTime.Day
* For the Microsoft documentation refer to

Debug.Print Now()                     '= 18/02/2024 09:23:12  
Debug.Print Day(Now()) '= 18
Debug.Print Day("04/07/2024") '= 4
Debug.Print Day(35678) '= 5
Debug.Print Day("15 February 2024") '= 15

© 2024 Better Solutions Limited. All Rights Reserved. © 2024 Better Solutions Limited Top