# IF FUNCTIONS

Closed
Matt Wilhelm - Feb 6, 2010 at 04:03 PM
Matt Wilehlm - Feb 9, 2010 at 02:02 AM
Hello,

I have this formula and I am trying to get it to calculate my overtime wage and my regular wage in the same cell. V16 is my overtime pay and V15 is my regular pay. The first part of the equation which is for my overtime works correctly but I can't seem to get the last half to calculate regular pay. If anyone has any idea they are greatly appreciated.

Matt

=IF(SUM(AE14)>40,(SUM(AE14)-40)*V16)+IF(SUM(AE14)<=40,-SUM(AE14>40,(SUM(AE14)*V15)))

## 2 responses

venkat1926 Posts 1863 Registration date Sunday June 14, 2009 Status Contributor Last seen August 7, 2021 811
Feb 6, 2010 at 08:01 PM
[QUOTE]
=IF(SUM(AE14)>40,(SUM(AE14)-40)*V16)+IF(SUM(AE14)<=40,-SUM(AE14>40,(SUM(AE14)*V15))) [/QUOTE]

Let me phrase the logic

If AE14 is greater than forty the cell should have the value of
(AE14-40)*V16+AE14*V15
Otherwise (means that if AE14 is less than equal to 40 then the value should be
AE14*V15

If this logic ok then the equation is

=IF(AE14>40,(AE14-40)*V16+AE14*V15,AE14*V15)

suppose AE14 is 45(more than 40),V16 is 20 and V15 25

then the above equation will give 1225

suppose AE14 is 35(less than or equal to 40) (naturally V15 and V16 remain the same the above equation will give 875

now I do not know whether you want to find this calculation for one person or for a number of people.