Forum Discussion
Help with changing the text within a text box depending on the date/quarter/year filters
- Anonymous3 years ago
Hi brookesmoore ,
You can follow the steps below to get it, please find the details in the attachment.
1. Create a measure as below
Measure = VAR _mindate = MIN ( 'Date'[Date] ) VAR _maxdate = MAX ( 'Date'[Date] ) RETURN IF ( _maxdate < DATE ( 2023, 2, 1 ), 0.98, IF ( _mindate >= DATE ( 2023, 2, 1 ), 0.94, BLANK () ) )2. Create a card visual to replace the textbox
Best Regards
- Anonymous3 years ago
Hi brookesmoore ,
You can make a little adjustment on the measure as below, please find the details in the attachment.
Measure =VAR _mindate =MIN ( 'Date'[Date] )VAR _maxdate =MAX ( 'Date'[Date] )RETURNIF (_maxdate < DATE ( 2023, 2, 1 ),0.98,IF ( _mindate >= DATE ( 2023, 2, 1 ), 0.94, "98%/94%" ))Best Regards
Hi brookesmoore ,
You can follow the steps below to get it, please find the details in the attachment.
1. Create a measure as below
Measure =
VAR _mindate =
MIN ( 'Date'[Date] )
VAR _maxdate =
MAX ( 'Date'[Date] )
RETURN
IF (
_maxdate < DATE ( 2023, 2, 1 ),
0.98,
IF ( _mindate >= DATE ( 2023, 2, 1 ), 0.94, BLANK () )
)
2. Create a card visual to replace the textbox
Best Regards
Thank you for your reply. This is working so far.
I would like to see if there is a way to display the text "98%/94%" should the date range fall into both ranges (before or on 1/31/2023 and after or on 2/1/2023). Is this possible?
- Anonymous3 years agoNot applicable
Hi brookesmoore ,
You can make a little adjustment on the measure as below, please find the details in the attachment.
Measure =VAR _mindate =MIN ( 'Date'[Date] )VAR _maxdate =MAX ( 'Date'[Date] )RETURNIF (_maxdate < DATE ( 2023, 2, 1 ),0.98,IF ( _mindate >= DATE ( 2023, 2, 1 ), 0.94, "98%/94%" ))Best Regards
- brookesmoore3 years agoFrequent Visitor
Works perfectly. Thank you!