Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.

Changing Presence of Page

Avatar

Former Community Member

I developed a PDF in Livecycle ES2 with several hidden pages (Presence = hidden in Object). I created a button that would change the presence of the page to visible with "xfa.resolveNode("Page38[1]").presence = "visible". That part works great, except when the user saves the document after clicking the button and the page(s) go back to hidden. The data is still present, but it appears the page presence going back to hidden for some reason. I am needing some help in understanding why this is?

2 Replies

Avatar

Former Community Member

Ok I hate to answer myself, but I did find a "duck tape" method. When the user clicks the button a hidden numeric field is populated with a 1. A hidden button with a If-Then statement reads that field at start up and if it is a 1 sets the presence of the hidden page to visible. I hate doing things like this because it is pretty sloppy but I really would like to understand why when a user sets a subform to visible and saves it, the subform resets it self.

Avatar

Former Community Member

Revision to earlier solution: Removed hidden button and placed the "If-Then" statement on the hidden numeric field itself. Works fine, except that the script is set to run on DocReady. If a user opens the form just to view they are still prompted to save the changes. Just kind of sloppy.