Skip to main content
New Participant
May 6, 2020
Answered

Show/hide buttons not working properly

  • May 6, 2020
  • 3 replies
  • 6334 views

I'm creating an interactive bingo card PDF for a client where the user clicks on the boxes to mark an X and mark five boxes in a row to 'win'. All the boxes are buttons with Xs on top all as buttons, but hidden until triggered. Clicking the box sets the visibility of the X on top to show. The problem is that when the next box is clicked the first X disappears, so only one X can be shown at once. In the visibility properties for the boxes, 'show' is only set for the corresponding X on top - all other buttons are set to 'ignore', but they aren't being ignored and hidden instead - why?

 

Here is the PDF - https://markharrington.design/wp-content/uploads/2020/05/bingo-card-forum.pdf - will need to be downloaded and opened with Acrobat.

 

Sometimes after clicking lots of random boxes, some of the X's stay visible for no explicable reason. If it's a problem with the layer order, what's the point of the 'ignore' markers. This is driving me mad, any help would be greatly appreciated!

This topic has been closed for replies.
Correct answer John Mensinger

That's brilliant thank you! I've got it all sorted now, by using an X stamp from another font. Out of interest is there a way to make the icon visible/hidden, like with the caption? 


Javascript for showing/hiding fields:

 

// Show

this.getField("FieldName").display = display.visible;

 

// Hide

this.getField("FieldName").display = display.hidden;

3 replies

manal shanableh
Adobe Expert
March 19, 2024

..

Adobe Expert
May 6, 2020

There is a way with a button and a javascript to have the appearance toggle on and off. I have sent you a file to examine

Adobe Expert
May 6, 2020

Here is the link to example of button and javascript

Link 

John Mensinger
John MensingerCorrect answer
Adobe Expert
May 11, 2020

That's brilliant thank you! I've got it all sorted now, by using an X stamp from another font. Out of interest is there a way to make the icon visible/hidden, like with the caption? 


Javascript for showing/hiding fields:

 

// Show

this.getField("FieldName").display = display.visible;

 

// Hide

this.getField("FieldName").display = display.hidden;

BobLevine
Adobe Expert
May 6, 2020

That's just the way it is. Once you put enough of those things into a PDF it just stops working. This is not now and has never been an InDesign issue. 

New Participant
May 6, 2020

So this is a PDF/acrobat issue and there is no way to fix it?

BobLevine
Adobe Expert
May 6, 2020
None I know of. You might want to check in the Acrobat forum, but I wouldn't hold out much hope.

I'm not a fan of interactive PDF for anything other than forms and even with that there are better alternative.