Forum Discussion
Help with parameter
- 5 years ago
Anonymous
With this code:
WTF = SUMX(WTF, [Working Hours Total] - 'Lunch Hours'[Lunch Hours Value])See here:
Half hour lunchOne hour lunch
Works for me. Maybe you could share sample data and your pbix file.
F
In your case you need to use a What If Parameter, which is located under the Modeling ribbon:
Cheers,
Fernando
Thank you Fernando,
That worked but I can't get it to work in a formula, it just keeps using the alternateresult of 0.50, even though the slider says a different value:
WTF = 'QGenda Compliance'[Worked Hours]-'Lunch Deduction Amount'[Lunch Deduction Amount Value]
- calerof5 years agoImpactful Individual
Anonymous
With this code:
WTF = SUMX(WTF, [Working Hours Total] - 'Lunch Hours'[Lunch Hours Value])See here:
Half hour lunchOne hour lunch
Works for me. Maybe you could share sample data and your pbix file.
F
- Anonymous5 years agoNot applicable
I got it working. What I did different...My Worked Hours was a Column, so I created it was a Measure (never know when to use column or measure), then I used the SUMX like you did and it worked. Thank you so much for your patience and help!
- calerof5 years agoImpactful Individual
Good to hear. Rule of thumb: Always use measures, never use calculated columns. Unless it's completely necessary.
😉
F