RTTSoftware Support Forum

PDF-ShellTools => Ideas/Suggestions => Topic started by: nightslayer23 on June 23, 2021, 07:15:12 AM

Title: Insert/Append Script for inserting one page over and over
Post by: nightslayer23 on June 23, 2021, 07:15:12 AM
Insert Append tool allows for inserting a pdf document to the start or end of any pdf file, but what about if it added it to every page of one zip file.

essentially creating a "back.pdf" pdf to be added as every even or odd.

"fronts file.pdf" + "back.pdf" every even page:

Result: New.pdf > front,back,front,back end
Title: Re: Insert/Append Script for inserting one page over and over
Post by: RTT on June 24, 2021, 03:13:39 PM
"zip file" ?
If any of these PDFs have more than one page, show me an example with page indexes, so I can better understand the goal.
Title: Re: Insert/Append Script for inserting one page over and over
Post by: nightslayer23 on June 26, 2021, 05:29:50 AM
Apologies - i meant pdf file. Unsure what happened there :Z

Perhaps two scenarios..

The page to insert will always be a single page, to be added in as the even (or back page) to the original file.

Second scenario: both files will be the same page count, eg 36 Fronts.pdf 36 backs.pdf, and they'd be combined as Odds (fronts) Evens (backs) > output.pdf

If for instance one file was a different count to the other, blank pages could be added?

The first scenario is the main application though. it basically works in the opposite to the current Insert/Append function, whereby instead of in the box "pages to include" being able to enter "odd" "even" "all" etc, the insert/append info section allows for the original file to say "after each page"
Title: Re: Insert/Append Script for inserting one page over and over
Post by: RTT on June 28, 2021, 02:37:34 PM
The page to insert will always be a single page, to be added in as the even (or back page) to the original file.
I'm going to change the insert/append pages tool to accept multiple insert indexes (current "insert point page" column), with support to index expressions (odd, even, Xn, etc.). This way it will be possible to do multiple inserts withing one run.

Quote
Second scenario: both files will be the same page count, eg 36 Fronts.pdf 36 backs.pdf, and they'd be combined as Odds (fronts) Evens (backs) > output.pdf
This interleave functionality is already possible with the merge tool. Just set for merging the fronts and backs PDFs and check the "merging sequencing through documents in the list" option. You can use the copies column to set the "back" pages to match the number of pages of the fronts one.
Title: Re: Insert/Append Script for inserting one page over and over
Post by: nightslayer23 on June 29, 2021, 01:11:27 PM
GREAT! next update I assume?

also, is there a way of creating shortcut commands for tasks?
Title: Re: Insert/Append Script for inserting one page over and over
Post by: RTT on June 30, 2021, 05:43:15 PM
next update I assume?
Probably.

Quote
is there a way of creating shortcut commands for tasks?
Windows global shortcut? What tasks? Please give me more details about what you are referring to.
Title: Re: Insert/Append Script for inserting one page over and over
Post by: nightslayer23 on July 01, 2021, 07:22:51 AM
next update I assume?
Probably.

Quote
is there a way of creating shortcut commands for tasks?
Windows global shortcut? What tasks? Please give me more details about what you are referring to.

for scripts and options from your menu
Title: Re: Insert/Append Script for inserting one page over and over
Post by: RTT on July 05, 2021, 03:35:16 PM
I don't think Windows has a way to add custom shortcuts to File Explorer, or to shell context menu items.
But using the PDF-ShellTools command line interface (https://www.rttsoftware.com/Manuals/STIndex.htm?pageURL=ST/English/CmdLine.htm), and some Windows tricks, this is doable.

Examples:
To call the Merge tool, add Merge to the target field
To call a script named "Print Arguments", add RunScript "ScriptName=Print Arguments" to the target field.

Now you just need to select, in the Windows File Explorer, the PDF files you want to process, and press the keyboard shortcut you assigned.

You can repeat the process to create shortcuts to all the other tasks you use often.