Get sum of only visible values?

carura

New Member
Joined
Sep 20, 2011
Messages
25
I have a table with autofilter enabled

I also have a cell that is supposed to show the sum of values in column C, cell C1

But the things is, the sum formula gets the sum of everything in column C.
I only want the formula to add items when it's visible in the table.
If I want to know the total expenses on bond paper, I select bond paper in column D's filter
Then the expenses will show up with bond paper but I till get the sum of everything in Cell C1.

Help please
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
Hey Carura,

You can do that with subtotal function.


=SUBTOTAL(9,C1:C100)

C100 has to be changed to the last cell in column C i.e, the cell just above the formula cell.

I hope it helps :)
 
Upvote 0

Forum statistics

Threads
1,223,239
Messages
6,170,947
Members
452,368
Latest member
jayp2104

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