Numbers IF formula for additions/subtractions on MacBook Pro

USING NUMBERS ON MAC BOOK PRO NEED AN "IF" FORMULA TO DO THE ADDITIONS AND SUBTRACTIONS. I CAN SEND A SAMPLE OF THE SPREAD SEET.

redsdad




MacBook Pro 16″, macOS 15.6

Posted on Jan 13, 2026 10:07 AM

Reply
Question marked as Top-ranking reply

Posted on Jan 14, 2026 4:12 PM

There is no "stop" like there is in programming.


This is the exact thing you asked for (other than "stop")

=IFS(AND(F29="",G29=""),"",F29>=0,G29+F29, F29<0, G29-F29)

The result is either a null string "" (which appears as a blank cell) or mathematical result.


However,

if F29>=0 then G29 + F29 else if F29<0 then G29-F29

can be simplified to G29+ABS(F29)

so the simplified answer is

IF(AND(F29="",G29=""),"",G29+ABS(F29))


Note that if F29 or G29 is empty, but the other has a value, the empty cell is treated as a zero. If you meant "if F29 OR G29 is empty then stop", replace the AND with OR.



3 replies
Question marked as Top-ranking reply

Jan 14, 2026 4:12 PM in response to Irv MacBUS

There is no "stop" like there is in programming.


This is the exact thing you asked for (other than "stop")

=IFS(AND(F29="",G29=""),"",F29>=0,G29+F29, F29<0, G29-F29)

The result is either a null string "" (which appears as a blank cell) or mathematical result.


However,

if F29>=0 then G29 + F29 else if F29<0 then G29-F29

can be simplified to G29+ABS(F29)

so the simplified answer is

IF(AND(F29="",G29=""),"",G29+ABS(F29))


Note that if F29 or G29 is empty, but the other has a value, the empty cell is treated as a zero. If you meant "if F29 OR G29 is empty then stop", replace the AND with OR.



Jan 13, 2026 11:11 AM in response to Irv MacBUS

Your question is too vague to get a direct answer.


IF() can certainly trigger additions and subtractions but you'll need to show more.


A sample screenshot of sample data should be sufficient, with an explanation of what you want the formula to do - for example:


"IF the cell B2 is positive, then add C2 and D2, otherwise subtract D2 from C2"


That's just a simple example and they can get far more complex, but knowing what logic you want to implement is key.


So, what is it you're trying to do?

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Numbers IF formula for additions/subtractions on MacBook Pro

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.