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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
DataAnalyst7
Frequent Visitor

Conditional Formating for Table Visualization in Power Bi Desktop

I have a table Visualization with percentages in power Bi. I want to format it in such a way that I can see an increase or decrease from the previous month. I am not sure how to go about it to be honest. But when I tried, I could see anything that could help me.PleaseScreenshot (28).png

2 ACCEPTED SOLUTIONS
Ritaf1983
Super User
Super User

Hi @DataAnalyst7 

Please refer to the linked discussion.

https://community.fabric.microsoft.com/t5/Desktop/Conditional-formatting-based-on-differences-betwee...

And the linked tutorial

https://radacad.com/month-over-month-calculation-in-power-bi-using-dax

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

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

Anonymous
Not applicable

Hi @DataAnalyst7 

You can refer to the following solution.

Sample data 

vxinruzhumsft_0-1702524075125.png

Create three measure

 

Format_fc =
VAR _preffc =
    CALCULATE (
        SUM ( 'Table'[%Stock to FC] ),
        'Table'[Monthnumber]
            = MAX ( 'Table'[Monthnumber] ) - 1,
        ALLSELECTED ( 'Table' )
    )
RETURN
    IF (
        NOT ( ISBLANK ( _preffc ) ),
        IF ( SUM ( 'Table'[%Stock to FC] ) - _preffc > 0, 1, 0 )
    )
Format_fcr =
VAR _preffcr =
    CALCULATE (
        SUM ( 'Table'[%Stock to FCR] ),
        'Table'[Monthnumber]
            = MAX ( 'Table'[Monthnumber] ) - 1,
        ALLSELECTED ( 'Table' )
    )
RETURN
    IF (
        NOT ( ISBLANK ( _preffcr ) ),
        IF ( SUM ( 'Table'[%Stock to FCR] ) - _preffcr > 0, 1, 0 )
    )
Format_rica =
VAR _prerica =
    CALCULATE (
        SUM ( 'Table'[%Stock to RICA] ),
        'Table'[Monthnumber]
            = MAX ( 'Table'[Monthnumber] ) - 1,
        ALLSELECTED ( 'Table' )
    )
RETURN
    IF (
        NOT ( ISBLANK ( _prerica ) ),
        IF ( SUM ( 'Table'[%Stock to RICA] ) - _prerica > 0, 1, 0 )
    )

Then put them to the conditional formatting of the [%Stock to RICA],[%Stock to FC],[%Stock to FCR], select icons

vxinruzhumsft_0-1702531499462.png

 

vxinruzhumsft_1-1702531512437.png

 

vxinruzhumsft_2-1702531525951.png

 

vxinruzhumsft_3-1702531540571.png

 

Output

vxinruzhumsft_4-1702531550315.png

 

Best Regards!

Yolo Zhu

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

2 REPLIES 2
Anonymous
Not applicable

Hi @DataAnalyst7 

You can refer to the following solution.

Sample data 

vxinruzhumsft_0-1702524075125.png

Create three measure

 

Format_fc =
VAR _preffc =
    CALCULATE (
        SUM ( 'Table'[%Stock to FC] ),
        'Table'[Monthnumber]
            = MAX ( 'Table'[Monthnumber] ) - 1,
        ALLSELECTED ( 'Table' )
    )
RETURN
    IF (
        NOT ( ISBLANK ( _preffc ) ),
        IF ( SUM ( 'Table'[%Stock to FC] ) - _preffc > 0, 1, 0 )
    )
Format_fcr =
VAR _preffcr =
    CALCULATE (
        SUM ( 'Table'[%Stock to FCR] ),
        'Table'[Monthnumber]
            = MAX ( 'Table'[Monthnumber] ) - 1,
        ALLSELECTED ( 'Table' )
    )
RETURN
    IF (
        NOT ( ISBLANK ( _preffcr ) ),
        IF ( SUM ( 'Table'[%Stock to FCR] ) - _preffcr > 0, 1, 0 )
    )
Format_rica =
VAR _prerica =
    CALCULATE (
        SUM ( 'Table'[%Stock to RICA] ),
        'Table'[Monthnumber]
            = MAX ( 'Table'[Monthnumber] ) - 1,
        ALLSELECTED ( 'Table' )
    )
RETURN
    IF (
        NOT ( ISBLANK ( _prerica ) ),
        IF ( SUM ( 'Table'[%Stock to RICA] ) - _prerica > 0, 1, 0 )
    )

Then put them to the conditional formatting of the [%Stock to RICA],[%Stock to FC],[%Stock to FCR], select icons

vxinruzhumsft_0-1702531499462.png

 

vxinruzhumsft_1-1702531512437.png

 

vxinruzhumsft_2-1702531525951.png

 

vxinruzhumsft_3-1702531540571.png

 

Output

vxinruzhumsft_4-1702531550315.png

 

Best Regards!

Yolo Zhu

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

 

 

 

 

 

Ritaf1983
Super User
Super User

Hi @DataAnalyst7 

Please refer to the linked discussion.

https://community.fabric.microsoft.com/t5/Desktop/Conditional-formatting-based-on-differences-betwee...

And the linked tutorial

https://radacad.com/month-over-month-calculation-in-power-bi-using-dax

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

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 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.