Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

Adding an instance of a page and using Pagination to control use of Master Pages

Avatar

Level 6

Hi all,

I have a one page form that is dynamic as the user can type multi lines in a table cell and the form can grow to multiple pages. I would like the user to have the ability to add an instance of the page but the new instance needs to always begin on a new page using the first master page (MPage1), this way the header shows for each instance of the page. However, if any instance of the page grows to more than the one page, it needs to grow onto the second master page (MPage2) where there is no header. If anyone knows how to make this happen, I would appreciate the help. I cant quite get it to work exactly how I want.

 

I have provided the form at the link below:

https://drive.google.com/drive/folders/1VDezpUn7Rg1pcq9QmwAkanrC0gVbLJoJ?usp=sharing

 

Thank you for your time,

Emilee

1 Accepted Solution

Avatar

Correct answer by
Employee
8 Replies

Avatar

Employee

Hi @nowackem ,

the best solutions are the simple ones

Your form will work the way you describe it when you change the Pagination settings of your Page1 to what I show here:

Kosta_Prokopiu1_0-1625468515505.png

 

Avatar

Level 6

@Kost7  Thank you for your response! I have tried this combination, however, it does not do what I need. When I click the button "Add Page" I need the added page to be placed on a new MPage1 not continued on the same page. It needs to appear as a brand new form on a new page but in the same document. Here is a picture of what your suggestion does, do you see how it starts its repeat in the middle of the page? I need that to be on a new MPage1. The kicker is that if the table expands by the user typing in multi lines in the table that needs to continue on MPage2. I hope that makes sense. Every click on "Add Page" should look like a stand alone form but within this file. If you have any questions, please let me know. 

Screenshot 2021-07-06 103851.png

Avatar

Correct answer by
Employee

Avatar

Level 6
I can not get to this link. I dont have access. Am I missing something?

Avatar

Level 6
It works only if my initial body row count in the table is large enough to make this a two page form. If I want it to open initially to a one page form it doesnt work. Maybe try to put 10 rows in the initial count and see if it works for you. It doesnt work for me. Please let me know what you find. Thanks!

Avatar

Employee
This was a tough one. I got the same problem with few lines. I had to find a trick to solve it. See the initialize event of Page1. https://documentcloud.adobe.com/link/review?uri=urn:aaid:scds:US:aa6e6343-d328-40c5-a844-d4b9b549154...