Spawing 2 tamplates at same time (connected cells)
As you can see, the code (under) generates two pages in different places. I need these two generated pages to have connected windows for adding images (you upload an image in one window and it also appears in the other) (name: P2.Template2.P1.Template.P2.Template.P1.Template.Image25 ). Above the images is another box with text that must not be linked (name:P2.Template2.P1.Template.P2.Template.P1.Template.Text22). These states are generated from the template, so if a new request for generation is added, i.e. 2 additional pages, these two pages must not be linked to the previously generated 2 pages. To repeat, I have a 4-page document that has an interactive button to generate new pages (when clicked, it generates 2 new pages that go to a specific location (code above that doesn't change)). When generating this I want the document to have 6 pages of which 4 pages will be text and images, but the box on sheet 2 and 4 should only be associated with images and not text. the windows on pages 3 and 6 must also be connected. Pages 2 and 3 or 4 and 6 must not be connected to each other
if (typeof lastPageForTemplate2 === 'undefined') {
var lastPageForTemplate2 = 2;
} else {
lastPageForTemplate2 += 1;}
this.getTemplate("Template2").spawn({ nPage: lastPageForTemplate2, bRename: true, bOverlay: false });
var totalNumberOfPages = this.numPages;this.getTemplate("Template4").spawn({ nPage: totalNumberOfPages, bRename: true, bOverlay: false });
this.calculateNow();;
