ItalianPlatinum
Well-known Member
- Joined
- Mar 23, 2017
- Messages
- 886
- Office Version
- 365
- 2019
- Platform
- Windows
I am looking to add a second criteria to the solution I was provided. I thought this could work but I get an error code. Would someone be able to see what I am doing wrong? Below is an example of my data.
VBA to check if today's date in range if not skip
I am looking for a line of code to stop my exiting code from running if it cannot find today's today in YYYYMMDD format in column B.
www.mrexcel.com
VBA Code:
'check if any dates and records in H in order to evaluate if not end sub
If Application.WorksheetFunction.CountIf(WsDIST.Range("B:B")) = 0 And WsDIST.Range("H" & rows.count).End(xlUp).row <= 1 Then