These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Button to hide Subform or Rectangle

lev
Registered: Feb 23 2011
Posts: 2
Answered

Hi everyone,
 
Two days looking through every conceivable forum and search engine has me clutching at straws. I cannot for the life of me get certain object to become invisible just by the press of a button.
 
Ultimately I will tie this script to something more useful, like when a user selects a certain radio-button selection or an item off a drop down list. But right now, I thought I'd make it real simple and just create a button that would try and hide two things. Neither seem to disappear. What am I missing???
 
My Formcalc Button code is:
 
form1.Subform1.presence = "invisible"
Rectangle1.presence = "invisible"
  
I have one subform with just three textfields and outside of this I also have a Rectangle. That's it. I'd love to attach it but don't know how :S
 
I get no errors when I click the button, but the subform or the rectangle don't disappear either.
 
Many thanks in advance.
Lev
  

My Product Information:
LiveCycle Designer, Windows
thomp
Expert
Registered: Feb 15 2006
Posts: 4411
Accepted Answer
Did you save the form as Dynamic?

Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script

lev
Registered: Feb 23 2011
Posts: 2
OMG....I have played with so many pieces of code and even looked at that whole Static and Dynamic thing and it turns out I never had the right working code WITH Dynamic at the same time :(

Unbelievable. I was starting to question the code and opening new docs and of course THIS time, I left it at static.

Sigh.

Thank you so much :)