Error in formula

fxtrtr17

New Member
Joined
May 27, 2020
Messages
7
Office Version
  1. 365
Platform
  1. Windows
I have dollar amts in A, B, C and D.
In D I6 entered income and set my formula to look at D16 comparing to B16 and if D16 is <, the result returned is A16; if D16 is > than B16, then D16 is subtracted from C16 and that result is rounded up.
My formula is returned the correct amount, but it is a negative. I suspect I have something wrong in the formula but cannot determine what. My formula is:
=CEILING(IF(D16<B16,A16,D16-C16),1)
Can anyone help?
Maybe there is a better way to write this?
Thanks!
 

Attachments

  • formula.PNG
    formula.PNG
    2.1 KB · Views: 3

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)
Shouldn't it be C16-D16 ??
VBA Code:
=CEILING(IF(D16<B16,A16,C16-D16),1)
 
Upvote 0

Forum statistics

Threads
1,215,403
Messages
6,124,714
Members
449,182
Latest member
mrlanc20

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top