Hello all.
In the switch 11 update 1 reference guide (page 57) I found the following sample script for summary of "annotations":
// Acrobat is used to make a summary of the annotations resulting in a file that shows you
the page
// content and the annotations per page.
// No arguments are required.
if($error == null)
{
try
{
var title = $doc.documentFileName + " summary"
$outfile = $outfolder + '/' + $filename + "_summary.pdf";
$doc.ANsummarize($doc, title, ANSB_Page, null, $outfile, null, false, true, false, false,
false, false);
$outfiles.push($outfile);
}
catch(theError)
{
$error = theError;
$doc.closeDoc( {bNoSave : true} );
}
}
$error
Trying this script using the acrobat configurator (version 1), all annotations in the resulting summary were moved away from their original position. Could somebody confirm this behaviour?
Furthermore I can't find a helpful explanation of the 'summarize' command of the acrobat scripting api. In a forum thread I found:
ANsummarize(doc, title, p, r, dest, fs, print, twoUp, useSeqNum, scale, noAssocDoc, filter, paperWidth, paperHeight)
The values doc, title, dest, print, twoUp, useSeqNum, scale, paperWidth, paperHeight are nearly clear, but p, r, fs, noAssocDoc and filter aren't!
Is there a documentation for this available?
Thanks in advance,
Thomas
---
OSX 10.6.8, Switch 11 update 1, Acrobat 10.1.1
Unexpected movement of annotations
-
- TOP CONTRIBUTOR
- Posts: 628
- Joined: Mon Nov 29, 2010 8:45 pm
- Location: Alpharetta GA USA
- Contact:
Unexpected movement of annotations
ANsummarize() is an undocumented API function.
p = sort method (use ANSB_Page to sort by page order)
r = reverse sort order (boolean)
You can also use this loop to print the annotations.
this.syncAnnotScan();
var annots = this.getAnnots({ nPage:0, nSortBy: ANSB_Page });
for (var i = 0; i < annots.length; i++) {
console.println(util.printf("%s,%s,%s", annots.author, annots.type, annots.contents));
}
Another option is to use PDFspy to dump the annotations (and lots more)
Dwight Kelly
dkelly@apago.com
Apago, Inc.
p = sort method (use ANSB_Page to sort by page order)
r = reverse sort order (boolean)
You can also use this loop to print the annotations.
this.syncAnnotScan();
var annots = this.getAnnots({ nPage:0, nSortBy: ANSB_Page });
for (var i = 0; i < annots.length; i++) {
console.println(util.printf("%s,%s,%s", annots.author, annots.type, annots.contents));
}
Another option is to use PDFspy to dump the annotations (and lots more)

Dwight Kelly
dkelly@apago.com
Apago, Inc.
Unexpected movement of annotations
Hello Dwight,
thank you for your explanations and your code. I'll try this next week. So there's no official API function from Adobe to summarize comments with Acrobat - neighter with javascript nor applescript?
Okay, I see: I've to speak once more with my boss about your software "and lots more" ;o)
Have a nice weekend,
Thomas
thank you for your explanations and your code. I'll try this next week. So there's no official API function from Adobe to summarize comments with Acrobat - neighter with javascript nor applescript?
Okay, I see: I've to speak once more with my boss about your software "and lots more" ;o)
Have a nice weekend,
Thomas