Forum Discussion

ChahindaAlyy's avatar
ChahindaAlyy
Microsoft Employee
2 years ago

color coding change on selection

i am working on a report that shows customer purchases on each product
the idea is the create a color coding as per the following: top transactions, mid transactions, and low transactions.
i alreay did the ranking for each product and i did the the color coding successfully.

the problem is, when i select a given customer name, the color coding changes.

for example, in the table, whthout any filtrations,  customer (x) is one of the top customers as per the color coding, when i select that Customer (X) from the (Cusotmer nme) slicer), the color coding changes to aanother color (mid transactions),

any idea how ro solve this? i need t slsect the customer name form the slicer and keep the same color coding as whitout filtrations

2 Replies

  • ChahindaAlyy whatever logic yu are using to calculate the color coding, you need to change that DAX measure to include ALL customers, not the selected one, so measure should have ALL function.

    • ChahindaAlyy's avatar
      ChahindaAlyy
      Microsoft Employee

      Hi parry2k 
      my Formulas are as follow:
      i am creating a formulas to calcuate the revenue by product,

      then created a formulas to rank by customer rankx

      rankx(ALLSELECTED(Table[Customer column]),[Total Product X],,DESC,Dense)
      then in coditional formating i based the conditional formatting on the ranking field
       
      i tried to remove allselected and insert "all" only, but did not change.