Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I have a button I would like to hide if the user hasnt selected a value from a column. Right now I am populating the value selected into a variable, so its like:
vName = Only(Table.Name)
So I would like to evaluate vName so that if it = '', then I will hide the button using the Show Condition. Any ideas how I can do this?
So IF vName = ''
then <hide>
ELSE
show.
in properties of the button, tab layout, section show:
set in the conditional box:
=getselectedcount(myField) > 0
let me know
What would be even cooler, would be to leave the buttons, but just fade them out, as opposed to hiding them, if that were possible...
in properties of the button, tab layout, section show:
set in the conditional box:
=getselectedcount(myField) > 0
let me know
Ah thanks, but the field is a string, not a number, will this make a difference as you have > 0 there. I was expecting ' '...
Nope that works perfectly! Thanks
Any ideas if I can just grey the button out and disable it, as opposed to hiding it?
You don't need to use a variable.
Just right click the button and go to the Background color window. In the "Base Color" area, choose "Calculated" and add your formula. The one shown below set the button background as Blue if the selected value is equal 1 and a light blue if it's not equal 1.
if(Field = 1, ARGB(255, 0, 0, 255), ARGB(50, 0, 0,255))
Cool, but even if its light blue, it will still be able to be enabled, right? I want to disable the function too.
There is a "Enable Condition" in the Button Properties Page. Just set it to Field = 1 (my example) and it will be disabled when a value not equal 1 is selected.
Perfecto. Many, many thanks.