Monday

A

Anonymous

How can I ask an application to do something each monday or first day of the
week...

is there a function First Day of the Week????
 
F

fredg

How can I ask an application to do something each monday or first day of the
week...

is there a function First Day of the Week????

The first day of the week where I live is Sunday.
So if you wish to test if the current date is a Monday, (WeekDay #2),
you could use:

If WeekDay(Date())= 2 Then
' It's Monday
' Do Something
Else
' It's not Monday
' Don't do anything
End If

Sunday is weekday #1, .... Saturday is #7

Look up the WeekDay() function in VBA Help to learn how to set the
first day of the week to a different day.
 
J

John Smith

Thank you very much for your help!


fredg said:
The first day of the week where I live is Sunday.
So if you wish to test if the current date is a Monday, (WeekDay #2),
you could use:

If WeekDay(Date())= 2 Then
' It's Monday
' Do Something
Else
' It's not Monday
' Don't do anything
End If

Sunday is weekday #1, .... Saturday is #7

Look up the WeekDay() function in VBA Help to learn how to set the
first day of the week to a different day.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top