• 411K Members
• 5,213 Online
• 466K Conversations

New Contributor

# Formula Help

I am creating a spreadsheet for my job. I need to set up a formula that if the specified cell = the word "Add," it will add two different cells together, as well as if it ="Delete", it will subtract said cells.... is there a way to do that? If so, can someone help me out with that?

Example of what I am trying to accomplish: If F2="Add" then Cell N3= C3+M3

If F2="Delete" then Cell N3=M3-C3

4 Replies

# Re: Formula Help

Please try below formula

=IF(F1="Add",C1+M1,IF(F1="Delete",M1-C1,""))

Sample file is also attached for your reference.

Highlighted

# Re: Formula Help

Hello @tinabthatsme,

It appears that you have just about figured the formula out yourself!

In formulaic form, what you described in cell N3 would be:

=If(F2="Add", C3+M3, If(F2="Delete","M3-C3,""))

Hope this helps!
PReagan

Perfect! Thanks!

# Re: Formula Help

Thank you! I didn't add the appropriate "" in the formula which is why I couldn't get it to work, so thank you!
Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
22 Replies
flashing a white screen while open new tab
cntvertex in Discussions on
13 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
28 Replies
PacketMon Components are not loading in WAC 1909
HotCakeX in Windows Admin Center on
2 Replies