Skip to main content
Known Participant
July 26, 2019
Question

Can a PDF file be opened and hidden from view?

  • July 26, 2019
  • 3 replies
  • 2535 views

I want to open a pdf, read from it,  but keep it hidden from view. Can this be done?

This topic has been closed for replies.

3 replies

Jim_MacD1Author
Known Participant
April 4, 2020

Still can't get bHidden to work. Yes, I put this.disclosed=true in document level.

 

Anyone have SIMPLE sample code using bHidden?

Thom Parker
Community Expert
April 4, 2020

Where are you using this code?

Please post the complete script.  

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
Thom Parker
Community Expert
April 13, 2020

Thanks for your responce. I have little knowlegde of Adobe - I'm afraid I don't understand the meaning of 'native list of arguments, or pass the arguments as an object'. Any chance of providing sample code which opens a hidden file called "SampleDoc.pdf"?

 

 

 

 


I already provided that code in my previous post. In fact, you already posted it on July 26th of last year. 

 

Everything you need to know has already been provided in the previous posts. However, if you do not know how to program using JavaScript, then you're chances of success are extremely low. I would strongly suggest you learn about programming in JavaScript, or hire a consultant to either create the code for you, or walk you through the process of developing it yourself. 

 

You have not answered one of the most critical questions posted here. Where is this code being used? For initial testing purposes it should be done from the console window.

You'll find a tutorial on the console here:

https://www.pdfscripting.com/public/Free_Videos.cfm#JSIntro

 

 

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
Joel Geraci
Community Expert
July 26, 2019

You can use JavaScript to open a PDF file and keep it hidden but in your use case, the document wll also need to be "disclosed" in order to use JavaScript to communicate data between documents.

try67
Community Expert
July 26, 2019

No.

Jim_MacD1Author
Known Participant
July 26, 2019

Can a pdf be hidden using "bHidden" command? The following is taken from

Adobe Acrobat 7.0.5

Acrobat JavaScript Scripting Reference

Manual

Example 3 (Acrobat 7.0)

Open a hidden PDF document, extract information from it, and close it.

oDoc = app.openDoc({

cPath:"/C/myDocs/myInfo.pdf",

bHidden: true

});

var v = oDoc.getField("myTextField").value;

this.getField("yourTextField").value = v;

oDoc.closeDoc();

Bernd Alheit
Community Expert
July 26, 2019

Yes, this is possible.