Link to home
Start Free TrialLog in
Avatar of Allan
AllanFlag for United States of America

asked on

Compare DayOfWeek

Hi Experts,

Having problem compare the day of the week

Dim strDayOfWeek = "Monday"

IF Now.DayOfWeek = strDayOfWeek THEN <-- HOw to compare?

END IF

Can you please help?

TIA!
Avatar of steveberzins
steveberzins

DayOfWeek is an enumeration...

so this would work

If DateTime.Now.DayOfWeek = DayOfWeek.Monday Then
ASKER CERTIFIED SOLUTION
Avatar of craskin
craskin
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Allan

ASKER

Ahh, yes I was looking for the .toString. Thanks.
I'll split the points.