Forum Discussion
Plump_Lil_Monk
3 years agoFrequent Visitor
What-If Parameter
Hi I have inherited a PBi dashboard which is a bit of a monster, But for this question, I have put together some mock data and visuals. Scenario: Users show which activities they have been doi...
- 3 years ago
Hi Plump_Lil_Monk ,
Try following logic:
1. Create your What-If parameter in Model section:
2. Create a new measure. Measure should work only for IT and Communication, for the rest the hours will not change. You can try something like this:Editable Hours =var _Activity = SELECTEDVALUE(TableX[Booking Activities])var _Hours = SUM(TableX[Hours Booked])returnSWITCH(_Activity,"Communication",_Hours * Parameter[Parameter Value],"IT",_Hours * Parameter[Parameter Value],_Hours)
FYI - this measure works also with Parameter Value, which is value connected to your What If table and slicer. Combining Parameter Value with Hours will solve your problem.
I Have an example in my own matrix.
As you can see, slicer has value = 10, so my hours in IT and Communication are 10x bigger. Other values are the same:
Migasuke
Memorable Member
3 years agoHi Plump_Lil_Monk ,
Try following logic:
1. Create your What-If parameter in Model section:
2. Create a new measure. Measure should work only for IT and Communication, for the rest the hours will not change. You can try something like this:
Editable Hours =
var _Activity = SELECTEDVALUE(TableX[Booking Activities])
var _Hours = SUM(TableX[Hours Booked])
return
SWITCH(
_Activity,
"Communication",_Hours * Parameter[Parameter Value],
"IT",_Hours * Parameter[Parameter Value],
_Hours)
FYI - this measure works also with Parameter Value, which is value connected to your What If table and slicer. Combining Parameter Value with Hours will solve your problem.
I Have an example in my own matrix.
As you can see, slicer has value = 10, so my hours in IT and Communication are 10x bigger. Other values are the same: