Forum Discussion

HPS1RT's avatar
HPS1RT
Frequent Visitor
2 years ago
Solved

Power BI table colour coding based on other visual

Hello Community, I have column chart and table in one report page. Is there a possibilty to display the colour coding in the table based on colour of that text value in other visual? ...
  • StrategicSavvy's avatar
    2 years ago

    Hi HPS1RT 

     

    Yes , it is possible. If you want to have control over specific colors over bars you can add new dimension to your table that will map category with color. 

     

    Then you can use conditional formatting in Matrix/Table or Column Char that will format colors based on Field Value based on Column including Hexidecimal/Color name.

     

    See the example below:

     

     

     

     

    Hope it helps!

  • Ritaf1983's avatar
    2 years ago

    Hi HPS1RT 
    You can create Dax with color coding and use a created measure for all the visuals. 
    For example :

    color = SWITCH(SELECTEDVALUE('Table'[category]),
    "a","red",
    "b","blue",
    "c", "#3f007d")

    or for graph :

    pbix is attached

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

  • Ritaf1983's avatar
    Ritaf1983
    2 years ago

    Hi HPS1RT 
    No, this can work only with Dax we don't have the functionality of coloring visuals based on other visuals, so you have to have some logic to get the colors.

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