How to add contents of another cell to formula

Harold R.

Board Regular
Joined
Sep 26, 2004
Messages
132
I have the following formula =(MAX(0,SUMIF(K29,">40")-40))*1.5 I need to add cell X20 to K29. I have tried
=(MAX(0,SUMIF(K29,X20),">40"))-40))*1.5
=(MAX(0,SUMIF(K29+X20),">40"))-40))*1.5
=(MAX(0,SUMIF(K29,X20)">40"))-40))*1.5
=(MAX(0,SUMIF(K29+X20)">40"))-40))*1.5
But it doesn't work. What am I doing wrong?
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result

mikerickson

MrExcel MVP
Joined
Jan 15, 2007
Messages
24,348
SUMIF(K29,">40")-40

=IF(K29>40,K29,0)-40

=either -40 or K29-40

So, MAX(0,SUMIF(K29,">40")-40)

=MAX(0,K29-40)

Does =MAX(0,K29+X20-40) give you the result you want?
 
Upvote 0

Forum statistics

Threads
1,191,118
Messages
5,984,749
Members
439,907
Latest member
Kayfabe

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
Top