Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
judeab_07
New Member

Change the value of one measure using another

Hi Guys,

 

I'm new to PBI and trying to figure out how to use measures. I'm trying to change the value of one measure, using another. Hope the measure I attempted to write will make it clear.

 

SlicerResult = IF(HASONEVALUE(ToggleTable[Value]),
                                                                    IF(VALUES(ToggleTable[Value]) = "Yes",[HideVisual]=0,[HideVisual]=1))
 
Basically I'm trying to use a slicer as a toggle button to hide or unide a visual. Bookmarks do not fit what I am looking for.
 
Thanks in advance,
Jude
5 REPLIES 5
judeab_07
New Member

Hi,

 

thank you for your response.

 

judeab_07_0-1668637620506.png

Here's what I'm trying to do. If I select "yes" the value of the card should change to 0 and if I select No, it should chnage to 1.

The value on the card is a measure called HideVisual, which I would like to change using the slicer.

 

Hope this helps.

it does help just not sure why you are doing it the way you are doing it.  

you might try it a different way ?

 

HideVisual=
IF (
    NOT ( ISBLANK ( ToggleTable[Value] ) && ToggleTable[Value] ) = "Yes",
    0,
    1
)





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




Hello,

 

That's because I am already assigning value to the measure HideVisual earlier.

 

HideVisual = IF([CheckFilter],1,0)
Here I'm checking if a filter has been applied on some visuals, and then the value will be given accordingly.
 
With this new measure I want to change the already set value of HideVisual.  Is this even possible?
 
Many thanks!

Providing some sample data with the expected solution to work through this would be the best way to figure that out.  Its really hard to give a solution without understanding how the data looks.





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




vanessafvg
Super User
Super User

can you in pictures explain exactly what you are trying to do, and what is not currently working?

 

Provide an example with some data so its clear what the solution is you are looking for.





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.