Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hello Everyone,
I am trying to create a map by pincode, and I am adding a condition to change the color of the map as per the condition. The Condition is working fine when the map is zoomed out. But When I click on any specific pincode, the color is default Blue. What I need to do is ensure that when a user selects any pincode from the slicer, the color remains the same.
Conditional formatting is working fine in this view:
When I select a pincode, the color changes to default Blue. It should remain the same as per the above graph.
Can anyone suggest if this will be fixed or not?
Regards,
Surekha
Solved! Go to Solution.
Hi @Surekha_PM -Hope you are using Azure map and you should be able to maintain consistent conditional formatting in your Azure Maps visual in Power BI, even when zooming in or selecting specific pincodes. can you try to add conditional formatting at bubble layer level and also use conditional fomatting type with Field values instead of rules or gradient.
Hope it helps.
Proud to be a Super User! | |
Hello,
Try using this approach and see if it works
Set Up Conditional Formatting in Your Map Visual:
Create a Measure for Conditional Formatting:
To ensure that colors are correctly applied based on conditions even when zoomed in, create a measure that determines the color. For example:
Pincode Color =
SWITCH(
TRUE(),
[Your Measure] > Threshold1, "Color1",
[Your Measure] <= Threshold1 && [Your Measure] > Threshold2, "Color2",
"ColorDefault"
)
Replace [Your Measure], Threshold1, Threshold2, and the color values with your actual measure and conditions.
Add Conditional Formatting to the Map:
Using Color By Field:
Add a map visual to your report and include the pincode field as well as any measure you are using for coloring.
In the Visualizations pane, go to the Format options (paint roller icon).
Expand the Data colors section.
Choose to format colors based on your measure or column. Use the measure you created (Pincode Color) to control the colors based on conditions.
Handle Selection and Filtering:
Ensure Consistent Formatting on Selection:
In the Format pane for the map visual, go to Data colors.
Ensure that the colors for each pincode are set to be conditional based on your measure or field, and not set to default colors.
Slicer Configuration:
If you have a slicer for pin codes, ensure it’s correctly filtering the data used by the map visual. When a user selects a pincode, the map should filter to that pincode and apply the same conditional formatting.
Check Map Settings:
Ensure that you don’t have any settings in the map visual that could override your conditional formatting when zoomed in. Check for any options related to color handling or default settings.
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Surekha_PM -Hope you are using Azure map and you should be able to maintain consistent conditional formatting in your Azure Maps visual in Power BI, even when zooming in or selecting specific pincodes. can you try to add conditional formatting at bubble layer level and also use conditional fomatting type with Field values instead of rules or gradient.
Hope it helps.
Proud to be a Super User! | |
User | Count |
---|---|
116 | |
73 | |
62 | |
50 | |
46 |
User | Count |
---|---|
173 | |
123 | |
60 | |
59 | |
57 |