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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
JoelPendery
Frequent Visitor

Highlights array not present when there is no Measures DataRoll

I'm having some issues with locating the highlighting array. I have built a visual with two Grouping DataRoles and one Measure Data Role (the measure roll may or may not be filled). I can observe the highlights array when the Measure DataRole is filled with data, however, when it is empty (the visual will still build when empty) there is no way to access the highlight array that resides in the categorical.values location as it is null at this level. I've tried to create a dummy class inside the powerbi.extensibility.visual module to use a filter to get a filtered value that can be accessed from the main visual building class, but predictably, I just ended up filtering all the data coming. Is there any way to get around this?

 

1 ACCEPTED SOLUTION

The highlighting array is specified if and only if Measure field is filled.

This is default and expected behavior of Power BI.

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

View solution in original post

4 REPLIES 4
JoelPendery
Frequent Visitor

I'm having some issues with locating the highlighting array. I have built a visual with two Grouping DataRoles and one Measure Data Role (the measure roll may or may not be filled). I can observe the highlights array when the Measure DataRole is filled with data, however, when it is empty (the visual will still build when empty) there is no way to access the highlight array that resides in the categorical.values location as it is null at this level. I've tried to create a dummy class inside the powerbi.extensibility.visual module to use a filter to get a filtered value that can be accessed from the main visual building class, but predictably, I just ended up filtering all the data coming. Is there any way to get around this?

 

The highlighting array is specified if and only if Measure field is filled.

This is default and expected behavior of Power BI.

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

Is there a way to get the highlight array any other way? Or, is there a way to implement two separate IVisual classes within one extensibility module? I basically have a hierarchy table with no measure data and want to highlight an entry based on a dropdown menu.

As far as I know, there aren't other ways unfortunately.

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

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.