Formula based off a selection
Hi All,
Could really use some help on trying to figure out a possible formula for the below:
There will be two options for freight provided, "COMPANY, and "eShipping". When "COMPANY" is selected the true cost will populate in our total cost column. When eShipping is selected I want cost *.10 to calculate in my total cost column. Any help would be greatly appreciated.
Best Answer

@Jamie Hawkins So we're missing some info here.
I am assuming the column containing the true cost value in the phrase "When "COMPANY" is selected the true cost will populate in our total cost column" is called True Cost.
I am assuming that when you say "When eShipping is selected I want cost *.10 to calculate" that by cost you also mean the True Cost column value, but multiplied by .10, yes?
In your screenshot, you have COMPANY inside quotes in the dropdown. This is how it appears in the sheet, right? That causes a parsing problem, so we can't just do a straight text comparison. We'll have to use CONTAINS.
This formula goes in your Total Cost column.
=IF(CONTAINS("COMPANY", [Freight Provider]@row), [True Cost]@row, IF([Freight Provider]@row = "eShipping", [True Cost]@row * .10))
Regards,
Jeff Reisman
Link: Smartsheet Functions Help Pages Link: Smartsheet Formula Error Messages
If my answer helped solve your issue, please mark it as accepted so that other users can find it later. Thanks!
Answers

@Jamie Hawkins So we're missing some info here.
I am assuming the column containing the true cost value in the phrase "When "COMPANY" is selected the true cost will populate in our total cost column" is called True Cost.
I am assuming that when you say "When eShipping is selected I want cost *.10 to calculate" that by cost you also mean the True Cost column value, but multiplied by .10, yes?
In your screenshot, you have COMPANY inside quotes in the dropdown. This is how it appears in the sheet, right? That causes a parsing problem, so we can't just do a straight text comparison. We'll have to use CONTAINS.
This formula goes in your Total Cost column.
=IF(CONTAINS("COMPANY", [Freight Provider]@row), [True Cost]@row, IF([Freight Provider]@row = "eShipping", [True Cost]@row * .10))
Regards,
Jeff Reisman
Link: Smartsheet Functions Help Pages Link: Smartsheet Formula Error Messages
If my answer helped solve your issue, please mark it as accepted so that other users can find it later. Thanks!
Help Article Resources
Categories
 All Categories
 14 Welcome to the Community
 10.5K Get Help
 62 Global Discussions
 46 Industry Talk
 386 Announcements
 3.5K Ideas & Feature Requests
 54 Brandfolder
 124 Just for fun
 50 Community Job Board
 466 Show & Tell
 40 Member Spotlight
 44 Power Your Process
 28 Sponsor X
 234 Events
 7.3K Forum Archives
Check out the Formula Handbook template!