I have a table with a date column along with a series of buttons that filter the date column for Today, Yesterday, -2 Days, -3 Days, -4 Days, -5 Days, -6 Days, etc.
Is there anyway I can add some form of visual indicator (change of button color? font color? badge?) to show which button is currently filtering the dates in the table? In other words, if the -2 Days button was the last button pushed, it gets some visual indicator until another button is pushed?
Yes!
To go back 4 days, I currently use this, but of course open to any suggestions to better ways to approach it:
SetControlValue([Hitlist Test Date.], List(
Today()-4,
Today()-4
))
Thank you!
In the label portion of your button write: If((today()-4).in(HitListTestDate), _color(ā#00000ā, āin Useā, ānot in useā))
Then, in the place of the 0ās put in the hex-value of the color you are after!
Then do the same for your other buttons but adjust the if criteria to make sure it matches the button action
Also- just personally Iād use all white buttons so the colored text stands out more clearly. Alternatively to the _color() formula you could also use _highlight()
in a recent video of yours (de-duplicating video?) i am prety sure i saw a progress-bar show up in some of your buttons for a few momentsā¦ or was i seeing things?
No no, you got that right @Agile_Dynamics !
So, yes it can be done as, apparently, itās an āold trickā from @Paul_Danyliuk !
I searched on the Community to find the āhowā but I wasnāt able to find a dedicated topic ā¦
(As I didnāt have the time to try and see if I could solve this riddle for myself )
Indeed it was a progress bar but I didnāt suggest it here because I didnāt see how that would work along what OP requested (highlighting a ācurrently activeā button in terms that itās not a long-running action but a yes/no state, i.e. indicating that āLast weekā was the last pressed number / the currently active setting).
I donāt mind making a quick tutorial on implementing a progress bar label sometime soon I thought it was pretty easy to solve without a tutorial for it.