ItalianPlatinum
Well-known Member
- Joined
- Mar 23, 2017
- Messages
- 793
- Office Version
- 365
- 2019
- Platform
- Windows
Hello - I am trying to create a if/then statement so if two dates equal it does this in code, if two dates don't equal it does this. but i am getting a mismatch error even before i get to my If and then statement:
Here is my code what am i doing wrong?
The ranges have formulas in them if that even matters
TODAY is just =TODAY()
FFWD just pulls last day prior to a BD or Holiday.
Here is my code what am i doing wrong?
The ranges have formulas in them if that even matters
TODAY is just =TODAY()
FFWD just pulls last day prior to a BD or Holiday.
VBA Code:
Sub RUN()
Dim FFWD&
Dim Today$
'Set Range
FFWD = Workbooks("XXXX").Sheets("COMPARE").Range("FFWD")
Today = Workbooks("XXXX").Sheets("COMPARE").Range("Today")
'check if today isn't weekend or holiday and run macro
If FFWD = Today Then