ISFILTERED doubt

sadath

Active Member
Joined
Oct 10, 2004
Messages
262
Office Version
  1. 365
Platform
  1. Windows
Hi,

I have a YEAR slicer in my Power BI and following DAX formula

IsFilter=isfiltered(SALESDATA[YEAR])

=if([IsFIlter],sum(SALESDATA[SALES]))

the YEAR slicer having contents like 2015,2016,2017

can i change the formula into
if I select 2015 in YEAR slicer show the result of =CALUCLATE(sum(SALESDATA[SALES]),SALESDATA[YEAR]="2015")
if i select 2016 in YEAR slicer show the result of =CALUCLATE(sum(SALESDATA[SALES]),SALESDATA[YEAR]="2016") and
if i select 2017 in YEAR slicer show the result of =CALUCLATE(sum(SALESDATA[SALES]),SALESDATA[YEAR]="2017")
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
What I think you are describing is the exact standard inbuilt behaviour of power pivot. If you put a slicer on salesdata[year] and write a measure sum(salesdata[sales]) added to your visual, then a click on the slicer will give the sales for that year. That is what it is designed to do out of the box. You don't need isfiltered and calculate.

am I misunderstanding something?
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,975
Messages
6,122,538
Members
449,088
Latest member
RandomExceller01

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