Show Buttons
Share On Facebook
Share On Twitter
Share On Google Plus
Share On Linkdin
Share On Reddit
Contact us
Hide Buttons

VBA-Excel: Date-Time Functions – Day()

Description:

The Day func­tion takes date as a para­me­ter and returns a num­ber between 1 and 31, that is the day of the month.

Format:

Day(strDate)

Arguments:
    • str­Date
      • Manda­tory
      • Type: Date
      • Date, whose day needs to be calculated.

Exam­ple:

Function FnDay()

   Dim strDate

   strDate = CDate("15-July-2013")    

   MsgBox "Day of " & strDate & " is -> " & Day(strDate)

End Function

 

DAY()

DAY()

 

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: