How can I fill in a field with a name if my Location column is a specific city?
I am attempting to autofill data into a field (person's name/contact) if the city is the one they administer. I am receiving an incorrect arguement statement error. Here is what I have so far.
=IF(CONTAINS("Milwaukee", Location@row, "Michelle"), IF(CONTAINS("Appleton", Location@row, "Stephanie"), IF(CONTAINS("Madison", Location@row, "Tammy"))))
Any help would be greatly appreciated!
Best Answer
-
An IF statement has three conditions, Expression, Value if True and Value if False.
Currently, you just have IF(CONTAINS stacked without resolving any of them, which is giving you the error.
I would recommend something more in line with the following:
IF(Location@row = "Milwaukee", "Michelle", If(Location@row = "Appleton", "Stephanie", If(Location@row = "Madison", "Tammy", "ERROR"))) essentially this formula is going to another IF statement if the preceeding IF statement was not true.
The "ERROR" will return if a value other than Milwaukee, Appleton, or Madison is selected. So make sure all locations have a name assigned.
@ me know if this doesnt help!
Answers
-
An IF statement has three conditions, Expression, Value if True and Value if False.
Currently, you just have IF(CONTAINS stacked without resolving any of them, which is giving you the error.
I would recommend something more in line with the following:
IF(Location@row = "Milwaukee", "Michelle", If(Location@row = "Appleton", "Stephanie", If(Location@row = "Madison", "Tammy", "ERROR"))) essentially this formula is going to another IF statement if the preceeding IF statement was not true.
The "ERROR" will return if a value other than Milwaukee, Appleton, or Madison is selected. So make sure all locations have a name assigned.
@ me know if this doesnt help!
-
@NickStaffordPM Thank you!! That worked perfectly!
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 63.4K Get Help
- 396 Global Discussions
- 213 Industry Talk
- 448 Announcements
- 4.7K Ideas & Feature Requests
- 141 Brandfolder
- 133 Just for fun
- 56 Community Job Board
- 454 Show & Tell
- 30 Member Spotlight
- 1 SmartStories
- 293 Events
- 35 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!