Forum Discussion

osama's avatar
osama
New Member
10 years ago

table conditional cell background color

I want to make a Table with a conditional cell background color, like if the cell value is greater then 6 it colors turn red else green.

 

Thanks in advance.

4 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Don't worry, you posted in the right section - its certainly a Power BI development quandry. 

    The only way I have done this before is using a custom visual that uses JQuery in its update function to re-style the cells in the out of the box table visual based off of their value. 

    Alternatively, you can create your own table visual using just javascript to generate the HTML elements from a table dataview, or use d3. 

    -Alex Potter

    • greggyb's avatar
      greggyb
      Resident Rockstar

      Anonymous, I guess we could both be right. I was interpretting this as a question about such functionality in native table visualizations in PBI.

       

      Creating a custom visual is certainly an option as well (:

      • noor's avatar
        noor
        Frequent Visitor

        Anonymous greggyb Could you guys please help me out. I am very struck in an issue. 

        I need to draw a table have some images columns. Has somebody already made this custom visual or do I need to create custom. If I need to create a new custom how can I do that? Please check the below attachment

         

        Thanks