Forum Discussion
Jeffrey_VC
3 years agoHelper III
constant line based on filter
Hello,
I'm trying to use a constant line into a stacked bar chart.
I want that the constant line is dynamic based on an filter.
This filter had three different values
- Normal
- Calamity
- Urgent
If I select for example "Urgent" the constant line must be 98% and when selected "Normal" the constant line must be 93%.
Hopefully someone can help me.
Jeffrey
Hi Jeffrey_VC
you may try something like
Line =
IF (
NOT ISEMPTY ( 'Table' ),
SWITCH (
SELECTEDVALUE ( SlicerTable[Value] ),
"Calamity", 0.90,
"Normal", 0.93,
"Urgent", 0.98
)
)
2 Replies
- tamerj1Community Champion
Hi Jeffrey_VC
you may try something like
Line =
IF (
NOT ISEMPTY ( 'Table' ),
SWITCH (
SELECTEDVALUE ( SlicerTable[Value] ),
"Calamity", 0.90,
"Normal", 0.93,
"Urgent", 0.98
)
)- Jeffrey_VCHelper III
tamerj1
Great! Thank you for your solution. This is working fine.