Jump to content

Acrobat Default Magnification


Suprem0
 Share

Recommended Posts

Hi Experts,

I want to create a script that will change the magnification og PDF files to "fitwidth". Searching the net, I found out that CosDoc can do this. But I'm not familiar with it, and even reading the Acrobat Core API did not help.

Here is an example script that I've got:

PDPageMode pageMode = 3;
PDDocSetPageMode (pdDoc, pageMode);
PDLayoutMode pageLayout = 1;
PDDocSetLayoutMode (pdDoc, pageLayout);
CosDoc cosDoc = PDDocGetCosDoc(pdDoc);
CosObj cosObj = CosDocGetRoot (cosDoc);
//CosObj newOffArray = CosNewArray(cosDoc,false,2);
CosObj val = CosDictGet(cosObj, ASAtomFromString("FitH"));
CosDictPut (cosObj, ASAtomFromString("FitH"), val);

So what are those two CosDoc (CosDoc cosDoc)? Are they variables? How can I use that in AutoIt?

If only I can configure how that line of codes work, maybe I can start this script.

So please if anyone can explain this, it will be a great help. Thanks in advance!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...