If Formula Between Values

dennyvle

New Member
Joined
Sep 12, 2014
Messages
8
Hello,

I'm trying to set up a formula to calculate social security expense every month. The problem is the social security has an annual max limit of $7,254.

So I have the monthly salary and the social security rate of 6.20%.

Here is an example:

JanFebMarAprMay
Salary $ 40,000.00 $ 40,000.00 $ 40,000.00 $ 40,000.00 $ 40,000.00
SS Rate6.20%6.20%6.20%6.20%6.20%
SS $ 2,480.00 $ 2,480.00 $ 2,480.00 $ 2,480.00 $ 2,480.00

<colgroup><col><col span="5"></colgroup><tbody>
</tbody>

In March, the social security already exceeds the $7,254 limit. I need the total social security in Jan-Mar to equal exactly $7,254.

Thanks in advance,
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
welcome to the board.

Assuming your table starts in A1, enter this in B4:

=IF(B2*B3>7254,7254,B2*B3)

Enter this in C4 and drag across:

=IF(SUM($B$4:B4)+C2*C3>=7254,7254-SUM($B$4:B4),C2*C3)
 
Upvote 0
This can probably be simplified but in the meantime I will post what I have:


Excel 2010
BCDEFG
3JanFebMarAprMay
4Salary4000040000400004000040000
5SS Rate6.20%6.20%6.20%6.20%6.20%
6SS24802480229400
Sheet2
Cell Formulas
RangeFormula
C6=IF(SUM($B$6:B6)+(C4*C5)<=7254,C4*C5,C4*C5-(ABS(7254-(SUM($B$6:B6)+(C4*C5)))))
 
Upvote 0

Forum statistics

Threads
1,214,929
Messages
6,122,315
Members
449,081
Latest member
tanurai

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