• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
1

Spawning and hiding pages

New Here ,
Jul 16, 2020 Jul 16, 2020

Copy link to clipboard

Copied

Hi,

 

I'm working on creating a form in Acrobat where the user (who will be using Reader) will select from a group of 5 radio buttons. 3 of these choices/radio buttons need to spawn and go to a page where they provide more detail. I've figured out how to use templates and spawning to have a template page hidden until the user clicks on one of the radio buttons and then go to that page (last page) using this code on each of the 3 radio buttons:

 

this.spawnPageFromTemplate("Driving.HighwayCode");
this.pageNum = this.numPages - 1;

 

The issue I have is that I only want the template page to be able to spawn once and then ideally hidden if one of the other 2 radio buttons are clicked. I've tried to create some code that when one of the spawning radio buttons is selected, a hidden checkbox changes to say the page has spawned and that if another of the buttons is selected then not to spawn along these lines: https://answers.acrobatusers.com/Limit-spawned-template-q231635.aspx but I've not managed to crack it.

 

Any help or advice gratefully received.

TOPICS
Acrobat SDK and JavaScript

Views

281

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
no replies

Have something to add?

Join the conversation