Batch add same action / same javascript on page x .. y
I have pdf's from scanned documents. Most pages have size A4 (210x297mm). 'Document Properties' > 'Initial View' > 'Page layout' is set to 'Two-up' (Cover page)', so that always 2 pages will be showed side by side, like reading a book. Now, few pages have the double size, A3 (297x410mm). Viewing them, 'Page layout' should switch to 'Single sided'. Going back or forward to an A4 page, 'Page layout' should switch back to 'Two-up'.
The only method I found for achieving this, was by adding an action to each page of the document. The trigger is 'Open page', the action 'javascript'. Depending on the page size:
this.layout = "TwoPageRight";
this.layout = "SinglePage";
My quesion: How can I add such (identical) actions with (identical) javascript snippets conveniently for page x to y ? I could not find any feature in preflight.
