Ark68
Well-known Member
- Joined
- Mar 23, 2004
- Messages
- 4,570
- Office Version
- 365
- 2016
- Platform
- Windows
I have this line of code ...
If worked fine when I was simply comparing for the term "OFF", but I have since needed to adapt it for anything beginning with "OFF". I assume a wildcard '*' will not work in this situation.
What must I change to include any term beginning with "OFF" or better yet, change the forumula to recognize null values ("") or any text values?
Code:
.Range("D1").Formula = "=if(C1="""",0,if(C1=""OFF*"",0, if(c1=""STAT"",7.5,(C1-B1)*24-0.5)))"
If worked fine when I was simply comparing for the term "OFF", but I have since needed to adapt it for anything beginning with "OFF". I assume a wildcard '*' will not work in this situation.
What must I change to include any term beginning with "OFF" or better yet, change the forumula to recognize null values ("") or any text values?