Skip to main content
New Participant
October 8, 2017
Question

Show hidden buttons one by one

  • October 8, 2017
  • 1 reply
  • 312 views

HI! I´d like to show some hidden buttons by clicking a visible one, but I just manage to show the buttons all at once. Can you help me???

Thanks in advance!!

This topic has been closed for replies.

1 reply

try67
Community Expert
October 8, 2017

Make sure the buttons each have a unique name.

New Participant
October 8, 2017

Yep, they have a unique name, the thing is when the button is clicked the 8 hidden buttons turn up all at once.

I'd like button #1 to turn up with the 1st click, #2 with the 2nd click ... Just using one button.

Thanks for the answer!!!!!

try67
Community Expert
October 8, 2017

Ah, I see. That requires using a script. It would be something like this:

var f1 = this.getField("Field1");

if (f1.display==display.hidden) {

     f1.display = display.visible;

} else {

    var f2 = this.getField("Field2");

    if (f2.display==display.hidden) f2.display = display.visible;

    else {

          var f3 = this.getField("Field3");

          if (f3.display==display.hidden) f3.display = display.visible;

          else {

              // etc.

          }

    }
}