This is a snippet of an Acrobat Javascript to extract files from a pdf document:
/* Extract Pages to Folder */
// regular expression acquire the base name of file
var re = /.*\/|\.pdf$/ig;
// filename is the base name of the file Acrobat is working on
var filename = this.path.replace(re,""
;
try {
for (var i = 0; i < this.numPages; i++)
this.extractPages(
{
nStart: i,
cPath: "/F/temp/"+filename+"_" + i +".pdf"
});
} catch (e) {
console.println("Aborted: "+e)
}
I'm a little bit confused at the line CPath: "/F/temp/"+..."
Is "/F/temp/" the same as "F:/"
How will I customize it to extract 3 pages at a time to a file that I want to hard-code?
/* Extract Pages to Folder */
// regular expression acquire the base name of file
var re = /.*\/|\.pdf$/ig;
// filename is the base name of the file Acrobat is working on
var filename = this.path.replace(re,""
try {
for (var i = 0; i < this.numPages; i++)
this.extractPages(
{
nStart: i,
cPath: "/F/temp/"+filename+"_" + i +".pdf"
});
} catch (e) {
console.println("Aborted: "+e)
}
I'm a little bit confused at the line CPath: "/F/temp/"+..."
Is "/F/temp/" the same as "F:/"
How will I customize it to extract 3 pages at a time to a file that I want to hard-code?