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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
Anonymous
Not applicable

Row based Conditonal formatting

Hi, 

 

I have a table in excel in which one of the row "Status", needs to be color based background format in PowerBI.

aruneshmee_0-1643903777338.png

 



For example, if it's "Development", it needs to be blue, if it's "Testing" it needs to be Yellow, etc. There are total of 5 colors. How do I approach this problem? I know there is coumn based conditonal formatting in PowerBi based on Gradient, rule etc but I could't find row based formatting. Any help is appreciated! 

The output should be something this this in PowerBI

aruneshmee_1-1643903832400.png

 


Thank you!

1 ACCEPTED SOLUTION
V-lianl-msft
Community Support
Community Support

Hi @Anonymous ,

 

Unfortunately, your model does not support this. In power bi, there are relationships between columns, which are not independent of each other. It is difficult to format field with DAX formula in your model.

Please try to transpose column1 in query editor.

Vlianlmsft_0-1644384602651.png

 

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

9 REPLIES 9
V-lianl-msft
Community Support
Community Support

Hi @Anonymous ,

 

Unfortunately, your model does not support this. In power bi, there are relationships between columns, which are not independent of each other. It is difficult to format field with DAX formula in your model.

Please try to transpose column1 in query editor.

Vlianlmsft_0-1644384602651.png

 

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

just remove status from var row_select and you are good to go

Anonymous
Not applicable

writesomething similar  as follow

 

Color Significance period new = 
VAR vMaxSelected = [coloumnrefrence or measure]
RETURN
    SWITCH(
        vMaxSelected,
        "declining", "red",
        "inclining", "light green",
        "stable","yellow"

 

then do conditional formation based on that measure

 

Anonymous
Not applicable

In VAR ROW_SELECT, how do refreence the Status row? I don't see any option like select row

aruneshmee_1-1643900955879.png

 

Anonymous
Not applicable

Use Status in var and refrence bcz it has all  row vlaues or you can put in a coloumn then move to rows

Anonymous
Not applicable

You mean VAR ROW_STATUS = SELECTEDVALUE(Table_Name[Column_Name][Status])  ?
It gives me error. 

aruneshmee_0-1643902295354.png

I'm new to PowerBI so I'm struggling a bit. Can you write that code line please? Table name = Live_Overview, and the Column contaning Status row is named "Column1"

 

Anonymous
Not applicable

@Anonymous I edited my first post to give a better idea of what I need. Thanks 

Thejeswar
Super User
Super User

Hi @Anonymous ,

The Issue is not very clear.

If possible, share the expected Output and give some more details on how the Status plays a role here?

Anonymous
Not applicable

This is the excel

aruneshmee_0-1643903721313.png

And this is what I need in PowerBI

aruneshmee_0-1643903864381.png


Thanks!

 

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors