Hi,
I have a date in format YYYYMMDD which I need to get the date from 100 days ago. Here's what I'm trying to do:
Dim date100DaysAgo As String = Format(Now() - 100, "yyyyMMdd")
However, I get a syntax error: in Now() - 100 which says: "Operator '-' is not defined for types 'Date' and 'Integer'. Any thoughts as to how I can overcome this?
Thank you!
I have a date in format YYYYMMDD which I need to get the date from 100 days ago. Here's what I'm trying to do:
Dim date100DaysAgo As String = Format(Now() - 100, "yyyyMMdd")
However, I get a syntax error: in Now() - 100 which says: "Operator '-' is not defined for types 'Date' and 'Integer'. Any thoughts as to how I can overcome this?
Thank you!