Using multiple IF(AND) statements in a formula
Hello, I am trying to create a column formula that will update Schedule health to a red, yellow, green, or blue circle using multiple IF and IF(AND) statements, but I continuously get the error message "#INCORRECT ARGUMENT SET"
Here is my formula:
=IF(IF(AND([End Date]@row - [Today's Date]@row <= 0, Status@row = "In Progress"), "Red"), IF(AND((15 >= [End Date]@row - [Today's Date]@row <= 30), Status@row = "In Progress"), "Yellow"), IF(AND(([End Date]@row - [Today's Date]@row >= 30), Status@row = "In Progress"), "Green"), IF(Status@row = "Complete", "Blue", " "))
Here is a screen shot of the columns and the formula in smartsheet:
I am not sure what I am doing wrong, and I've been fiddling with this formula for a few days now. Can anyone help me with this issue? Do I need to separate conditions further? for ex:
Instead of: IF(AND((15 >= [End Date]@row - [Today's Date]@row <= 30), Status@row = "In Progress"), "Yellow")
Do : IF(AND([End Date]@row - [Today's Date]@row <= 30, [End Date]@row - [Today's Date]@row <=15, Status@row = "In Progress"), "Yellow")
Any help would be greatly appreciated
Best Answer
-
Give this a try:
=IF(Status@row = "Complete", "Blue", IF(Status@row = "In Progress", IF([End Date]@row< TODAY(), "Red", IF([End Date]@row< TODAY(30), "Yellow", "Green")))
Answers
-
Give this a try:
=IF(Status@row = "Complete", "Blue", IF(Status@row = "In Progress", IF([End Date]@row< TODAY(), "Red", IF([End Date]@row< TODAY(30), "Yellow", "Green")))
-
Paul, Thank you SO much! That worked perfectly, I was definitely over complicating my formula. I appreciate your expedient response!
-
Happy to help. 👍️
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 441 Global Discussions
- 140 Industry Talk
- 472 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 496 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!