These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Batch sequence not reponding as expected after upgrade

rustyvz
Registered: Apr 6 2009
Posts: 3
Answered

Hello,

I'm new here, but spent the last few workdays reading the forums looking for an answer or even a hint as to why the following is not working anymore after we upgraded.

Info:
Upgraded from Adobe Acrobat 7 to 9
Two 'Batch Sequences' in AA7 worked fine.
First gathered a count of files to process.
Second used the count to loop through files, creating a report.

These scripts worked fine before, creating a report showing path, title, subject and author for the selected files.

Currently, on a machine with AA7 installed, 8 pages are generated.

The same scripts, ran against the same files, only generates one page via AA9.
That page is identical to the first page from AA7.

The count is counting properly (console write show status) in AA9, but only the one page gets created.

I'm including the important parts of the second script below for reference.
There is looping, and it works, but it is not important (I don't believe) to this problem.

global.rep = new Report();
global.rep.size = 1.2;
global.rep.style = "NoteTitle";
global.rep.writeText(" ");
global.rep.outdent(20);
global.rep.color=color.blue;

global.rep.writeText(this.path);
global.rep.color=color.black;
global.rep.writeText(this.info.title);
global.rep.writeText(this.info.subject);
global.rep.writeText(this.info.author);

var docRep = global.rep.save("/c/myReports/DocInfoReport.pdf");

I'd appreciate any help trying to figure out how to resolve this issue.

If, by chance, I have not followed forum rules, I am sorry. I did my best to be detailed, yet not posting too much code (don't need a code review!).

Thanks!
rusty

My Product Information:
Acrobat Pro 9.1, Windows
try67
Expert
Registered: Oct 30 2008
Posts: 2398
There's several bugs in version 9 with the Report object. One of them is that it fails to automatically create a page break. You need to keep a (global) lines counter and manually add a page break when you arrive to the end of the page. Count how many lines fit on the first page and use that as your threshold.

- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com