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
Anonymous
Not applicable

Certain Fields are not Available as "Field Value" in conditional formatting

When I am attempting to create icons for my values in a table, certain values are not available as "Field Value".  They are all set as decimal numbers as their data type.  I am wondering if it could have something to do with my excel file? Please help!

morgre7_0-1606860887452.png

 

1 ACCEPTED SOLUTION
v-easonf-msft
Community Support
Community Support

Hi, @Anonymous 

No,there is no any simple way to make these values available as field values .

You have to create a measure  like below ,then apply it to  icon conditional formatting  of any field's you want:

 

icon format by field = 
VAR studentOutcomes = SUM (Sheet1[Student Outcomes])
    RETURN
    SWITCH ( 
        TRUE(),
        studentOutcomes>=0 && studentOutcomes<60, "FlagLow",
        studentOutcomes>=60 && studentOutcomes<90, "FlagMedium",
        studentOutcomes>=90 && studentOutcomes<100, "FlagHigh",
        studentOutcomes=100, "FlagBlack",
        "CircleLow"
    )

 

53.png

If you are not familiar with creating measures, it is  suggest to  "format by Rules ".

55.png


You can check my pbix for more details.

 

Related threads:

https://community.powerbi.com/t5/Desktop/What-are-the-icon-IDs-In-July-update/m-p/752075#M362440 

https://community.powerbi.com/t5/Desktop/Icons-Conditional-Formatting-by-Field/m-p/757235 

 

Best Regards,
Community Support Team _ Eason

 

View solution in original post

3 REPLIES 3
v-easonf-msft
Community Support
Community Support

Hi, @Anonymous 

No,there is no any simple way to make these values available as field values .

You have to create a measure  like below ,then apply it to  icon conditional formatting  of any field's you want:

 

icon format by field = 
VAR studentOutcomes = SUM (Sheet1[Student Outcomes])
    RETURN
    SWITCH ( 
        TRUE(),
        studentOutcomes>=0 && studentOutcomes<60, "FlagLow",
        studentOutcomes>=60 && studentOutcomes<90, "FlagMedium",
        studentOutcomes>=90 && studentOutcomes<100, "FlagHigh",
        studentOutcomes=100, "FlagBlack",
        "CircleLow"
    )

 

53.png

If you are not familiar with creating measures, it is  suggest to  "format by Rules ".

55.png


You can check my pbix for more details.

 

Related threads:

https://community.powerbi.com/t5/Desktop/What-are-the-icon-IDs-In-July-update/m-p/752075#M362440 

https://community.powerbi.com/t5/Desktop/Icons-Conditional-Formatting-by-Field/m-p/757235 

 

Best Regards,
Community Support Team _ Eason

 

amitchandak
Super User
Super User

@Anonymous , One of the option with field value is return color or hexcode. You can create a measure do so.

example

Colour =
SWITCH(TRUE(),
'Table'[Date] < TODAY(), "red",
'Table'[Date] = TODAY(), "orange",
"green")

Colour =
SWITCH(TRUE(),
max('Table'[Month Year]) = "Jan-2020", "red",
Max('Table'[Month Year]) < "Feb-2020", "orange",
//keep on adding
"green")

 

 

https://radacad.com/dax-and-conditional-formatting-better-together-find-the-biggest-and-smallest-numbers-in-the-column
https://docs.microsoft.com/en-us/power-bi/desktop-conditional-table-formatting#color-by-color-values

Anonymous
Not applicable

Thank you so much for responding, but this is above my skill level in power bi.  I really do not know how to code.  I am hoping there is a simple way to make these values available as field values so that I can use the icons.  Do you know of a simpler way by any chance?  Thank you again for responding!

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.