Referring different cells when slicer filter is applied

fred69

New Member
Joined
Nov 19, 2022
Messages
1
Office Version
  1. 365
Platform
  1. Windows
Hello everyone

I need your help. I have excel experience, but I'm far from a pro.
Is there a way you can refer to different cells when a slicer filter is applied?
Eg. the slicer filters January and a certain cell shows the value of January, but when the slicer filter is set to July in the same cell it should show the value of July. (See pictures).
I doubt this is possible with a function, but maybe it is with VBA?

Would be a great help if someone knew how to code this :)
Thanks!
 

Attachments

  • image_2022-11-19_140829943.png
    image_2022-11-19_140829943.png
    6 KB · Views: 6
  • image_2022-11-19_140925316.png
    image_2022-11-19_140925316.png
    6.4 KB · Views: 6

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
Is your slicer attached to an Excel Table or an Excel Pivot table ?

If a table can't you just put a sub-total on the table and pick up the Table total in your dependant cell eg.

1668946097906.png


Book1
ABCDEFGHI
1PeriodAmtSpent this month400
3Jul200
6Jul200
8Total400
9
10
11
12
Sheet1
Cell Formulas
RangeFormula
I1I1=Table1[[#Totals],[Amt]]
B8B8=SUBTOTAL(109,[Amt])


For a pivot table you can just pick up the the total per the pivot.

1668946201795.png


You can even display the selected month - see 7.5 min video TeachExcel >
 
Upvote 0

Forum statistics

Threads
1,213,529
Messages
6,114,155
Members
448,554
Latest member
Gleisner2

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