Forum Discussion

ptmuldoon's avatar
ptmuldoon
Resolver I
2 years ago
Solved

Creating a Measures Slicer; Formatting Issue

Note, I am currently working with Excel, Power Query, and Power Pivot, and will move this is to Power BI model in the near future.

 

I am attempting to create a slicer where the user can then change the measure easily, and found this how here, and got it work ok

hXXps://sqljason.com/2012/11/measure-selection-using-slicers-in.html

 

But the issue I'm facing is that when I format a particular measure, the values in the pivot table switch to text and you can not highlight them and get a total, etc.

 

This is the basic measure:

MsrValue:=switch (TRUE,
Min ( MyMeasures[ID] ) = 1, [Amount],
Min ( MyMeasures[ID] ) = 2, Format([Last 3 Amount], "Currency"),
Min ( MyMeasures[ID] ) = 3, [YTD Amount]
)

And when using that in a pivot table, the measure formatted as currency appears as text in the pivot table, while the other 2 will show as a number value. You can see that here below as the Last 3 Amount formatted in Currency is left justified in the values.

 

 

2 Replies