Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hola a Todos,
Por favor su ayuda para poder colocar color de fondo en los espacios vacíos de una matriz, el color debe obedecer a la condición dada según la línea. Actualmente he logrado realizar el color de fondo para las celdas que si tiene valores con la siguiente medida:
Color =
Var _ind = SELECTEDVALUE(Tabla[Estado])
return
SWITCH(TRUE(),
_ind= "CONCLUIDA","#ADDFCD",
_ind= "ACTIVA", "#FAE9A0",
_ind= "CANCELADA", "#F1BDBC"
)
- Lo ideal que se requiere es como la siguiente imagen:
Muchas gracias por su apoyo.
Solved! Go to Solution.
Hi , @TdlmRS
According to your description, you want to show colors for the whole row.
For your need , here are the steps you can refer to :
(1)This is my test data:
(2)Not all colors are displayed, the main reason is that the data is real, we need to create a calculated table to complete the data.
Table 2 = ADDCOLUMNS( CROSSJOIN( ALL('Table'[Nombres],'Table'[Sub]) , VALUES('Table'[Column])) , "Value" , CALCULATE( SUM('Table'[Value]) , TREATAS({[Column]},'Table'[Column]),TREATAS({[Sub]},'Table'[Sub]),TREATAS({[Nombres]} ,'Table'[Nombres])), "Estado", CALCULATE( MAX('Table'[Estado]) , TREATAS({[Column]},'Table'[Column]),TREATAS({[Sub]},'Table'[Sub]),TREATAS({[Nombres]} ,'Table'[Nombres]))
)
Then wen can get the table like this:
(3)We also can create a measure like this:
Measure = IF( SUM('Table 2'[Value])<> BLANK() ,SUM('Table 2'[Value]) ,UNICHAR(10))
Then we can put the measure on the visual and we can also configure the color as background and we can get your need:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi , @TdlmRS
Of course , you can do it, you just need to select this in configuration:
The result is as follows:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi , @TdlmRS
According to your description, you want to show colors for the whole row.
For your need , here are the steps you can refer to :
(1)This is my test data:
(2)Not all colors are displayed, the main reason is that the data is real, we need to create a calculated table to complete the data.
Table 2 = ADDCOLUMNS( CROSSJOIN( ALL('Table'[Nombres],'Table'[Sub]) , VALUES('Table'[Column])) , "Value" , CALCULATE( SUM('Table'[Value]) , TREATAS({[Column]},'Table'[Column]),TREATAS({[Sub]},'Table'[Sub]),TREATAS({[Nombres]} ,'Table'[Nombres])), "Estado", CALCULATE( MAX('Table'[Estado]) , TREATAS({[Column]},'Table'[Column]),TREATAS({[Sub]},'Table'[Sub]),TREATAS({[Nombres]} ,'Table'[Nombres]))
)
Then wen can get the table like this:
(3)We also can create a measure like this:
Measure = IF( SUM('Table 2'[Value])<> BLANK() ,SUM('Table 2'[Value]) ,UNICHAR(10))
Then we can put the measure on the visual and we can also configure the color as background and we can get your need:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Excelente!. Pude lograr lo requerido.
Solamente no puedo colocar los totales en color blanco, pero es secudario.
Muchas gracias.
Hi , @TdlmRS
Of course , you can do it, you just need to select this in configuration:
The result is as follows:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
User | Count |
---|---|
94 | |
86 | |
78 | |
70 | |
63 |
User | Count |
---|---|
114 | |
101 | |
97 | |
66 | |
59 |