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.
Hi
I have created one Power BI report and I am showing up one table view in my report. There is one column in my table which is holding values as "R", "G" and "Y" and I want to show "R" cell with RED background color, "G" with Green color and cell with "Y" value with Yellow color as Backgroud color. Is this possible ?
Solved! Go to Solution.
Make sure you have latest Power BI Installed.
1. Create a Custom Column and assign the Color Codes by using Switch function. Example:
ColorCodes = SWITCH(TRUE(), Table1[Color Symbol] = "B", "#0000FF", Table1[Color Symbol] = "R", "#FF0000", Table1[Color Symbol] = "G", "#008000", Table1[Color Symbol] = "Y", "#FFFF00")
2. Go to formatting Tab, select Conditional Formatting and then Select Background and then Select Field Value and then Select ColorCodes Column from the list. I.e.
is there a way to do this formula for multiple columns? My example is that I've created a series of columns that all show either a task as "COMPLETE" or "INCOMPLETE". I want any instance with "INCOMPLETE" to be shown as a red box across a series of 2-6 columns. Is this something that is do-able?
Make sure you have latest Power BI Installed.
1. Create a Custom Column and assign the Color Codes by using Switch function. Example:
ColorCodes = SWITCH(TRUE(), Table1[Color Symbol] = "B", "#0000FF", Table1[Color Symbol] = "R", "#FF0000", Table1[Color Symbol] = "G", "#008000", Table1[Color Symbol] = "Y", "#FFFF00")
2. Go to formatting Tab, select Conditional Formatting and then Select Background and then Select Field Value and then Select ColorCodes Column from the list. I.e.
@rocky09 thank you for your answer. I believe that is exactly what I need as well. However, I am so new to PowerBI, I don't even know where to put that DAX code. Can you provide some more detailed steps to implement your answer. I believe I can figure out how to add the column in the table. But some more on that might be helpful as well. Piecing all this together off YouTube videos and forum posts has been rough. Thank you!
Step 1 Create custom column assign value(numeric 1=red, 2=green, 3=yellow to them using conditional column (for e.g. new column name "index")
Step 2 once created select column which you want to format
Step 3 go to conditional formating >> backgroung formating >> formating applies to (select column)
Step 4 colors by rule
1 is red
2 is green
3 is yellow
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
118 | |
104 | |
77 | |
73 | |
52 |
User | Count |
---|---|
145 | |
109 | |
109 | |
90 | |
64 |