Skip to main content
Inspiring
Feb 21, 2022 1:55 PM UTC
Question

In Adobe acrobat, How to set the New Window in Open in dropdown using win32/vc++

Hi Team,

How to set the New window setting in Open in Dropdown in Adobe acrobat.

This topic is closed to new replies. Start a new post to keep the conversation going.

31 replies

try67
Community Expert
Community Expert
Feb 23, 2022 9:07 AM UTC

[Question moved to the Acrobat SDK forum]

Translate
Inspiring
Feb 24, 2022 10:06 AM UTC

Hi, I'm using this way to set the property new window? please help. If wrong please correct it.

PDDoc myPDDoc = AVDocGetPDDoc(avDoc);
AVPageView myPageView = AVDocGetPageView(AVDocFromPDDoc(myPDDoc));
PDViewDestination pdvDes = AVPageViewToViewDest(myPageView,ASAtomFromString("XYZ"),myPDDoc);
Create a PDAction objectPDAction myAction = PDActionNewFromDest(myPDDoc, pdvDes, myPDDoc);

 

CosDoc cosDoc = PDDocGetCosDoc(myPDDoc);
CosObj cosDisctAction = PDActionGetCosObj(myAction);
CosDictPut(cosDisctAction, ASAtomFromString("New window"), CosNewBoolean(cosDoc, FALSE,TRUE));
//Attach an action to the bookmark
PDBookmarkSetAction(aBookmark, myAction);

Translate
Legend
Feb 24, 2022 10:41 AM UTC

It seems you are guessing. There would almost never be a space in an atom string. There's no need to guess. As I said, this is in the PDF Reference. Here is Adobe's PDF 1.7 reference https://www.adobe.com/content/dam/acom/en/devnet/pdf/pdf_reference_archive/pdf_reference_1-7.pdf See page 655.

But you have another problem too. This option is only on a Remote Go-To action. You are not creating a Remote Go-to action. Your example is trying to set this on a link to page in the same document, but it's only available on links to another document (since only then is there the possibility of having two different documents, one in a new window). Also note that this is largely ignored by PDF viewers (though not by Acrobat Reader).

Translate
Bernd Alheit
Community Expert
Community Expert
Feb 21, 2022 2:40 PM UTC

What dropdown does you mean?

Translate
Inspiring
Feb 21, 2022 3:34 PM UTC

 

How to setup setting new window in this option.

Translate
Bernd Alheit
Community Expert
Community Expert
Feb 21, 2022 4:07 PM UTC

Is this a link in a PDF document?

Translate