Forum Discussion
Anonymous
2 years agoNot applicable
Create Visual on frontend measures
Hi, I have created one measure on PowerBI Desktop having only pass and fail values based on logic, now we want to create bar type chart on count of these pass and fail values. Is it possible to ...
rajendraongole1
2 years agoSuper User
Hi Anonymous - Can please share some sample data for more analysis, it helps to understand
as per my understanding , you can create a measure that uses a SWITCH statement to dynamically count Pass and Fail based on a selected value
DynamicCount =
SWITCH (
SELECTEDVALUE('PassFailTable'[PassFail]),
"Pass", CALCULATE(COUNTROWS('YourTable'), 'YourTable'[PassFailMeasure] = "Pass"),
"Fail", CALCULATE(COUNTROWS('YourTable'), 'YourTable'[PassFailMeasure] = "Fail"),
BLANK()
)
Hope it works and helps
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!