Switch Formula
Hello,
I have recently integrated a project plan from MS plan to Smartsheet's however I can't seem to get the auto RAG Switch function working working as it was in Project Plan. This is the formula I used. Can anyone please help :)
Switch( ([% Complete] = 100), "C", ([Baseline Finish] < Now()), "R", ([Finish] > [Baseline Finish]), "A", ([Finish] <= [Baseline Finish]), "G", True, "ERROR!" )
Answers
-
There is no SWITCH function in Smartsheet. Use nested IF to achieve the same.
-
Thanks for the contribution Sameer, I've tried using IF but it is not working. Do you happen to know how the formula would be set out to achieve the same result please? or anyone else?
-
See if this works,
= IFERROR( IF([% Complete]@row = 100, "C", IF([Baseline Finish]@row < TODAY(), "R", IF([Finish]@row > [Baseline Finish]@row, "A", "G") ) ), "ERROR!")
-
Still not working and says inseparable.
I'd also like to use symbols: Red, Yellow, Green, Blue
Blue being complete
= IFERROR(IF([% Complete]@row) = 100, "C", IF([Baseline Finish]@row) < TODAY(), "R", IF([Actual Finish]@row) > [Baseline Finish]@row, "A", "G"))),"ERROR!")
-
Don't suppose you can help with this one too @Sameer Karkhanis
https://community.smartsheet.com/discussion/88341/if-function/p1?new=1
-
To add to Sameer's excellent advice/answer.
Try something like this.
= IFERROR(IF([% Complete]@row) = 1, "Blue", IF([Baseline Finish]@row) < TODAY(), "Red", IF([Actual Finish]@row) > [Baseline Finish]@row, "Yellow", "Green"))),"ERROR!")
Did that work/help?
I hope that helps!
Be safe and have a fantastic weekend!
Best,
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
✅Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!
SMARTSHEET EXPERT CONSULTANT & PARTNER
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35
Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.
-
Hi thank you for your contribution. It comes back saying #UNPARSEABLE?
-
Happy to help!
Try this instead. (I noticed some errors + I modified it a little)
= IFERROR(IF([% Complete]@row = 1, "Blue", IF(AND([Baseline Finish]@row < TODAY(), [Baseline Finish]@row <> ""), "Red", IF([Actual Finish]@row > [Baseline Finish]@row, "Yellow", "Green"))), "ERROR!")
Did that work?
✅Remember! Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!
SMARTSHEET EXPERT CONSULTANT & PARTNER
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35
Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 439 Global Discussions
- 138 Industry Talk
- 471 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 488 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!