Hello all,
I encounter a similar issue with the ImportPage() method.
I want to make a new PDF doc with some pages of others docs. So I create one document for each page I want to import. The issue comes here. The resulting one-page-doc has the same weight as the original doc. Which means that the merged doc is many larger that it has to be !
For example, I export 2 pages of a 4MB PDF, and merged thoses pages. The resulting PDF weight is 8MB .... Not usable at all !
The one-page creation routine I use is :
Document.ImportContext importContext = document.ImportStart(docToMerge);
if (importContext != null) {
document.ImportPage(importContext, page, 0);
importContext.Destroy();
}
boolean save = document.Save();
document.Close();
docToMerge.Close();
Is there a call missing or something ?