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

Button to copy text field value to notepad

smilem
Registered: Apr 1 2008
Posts: 101

Anyone? I need to paste the data into another program like notepad.

I tried

Let's say you create a variable named "textValue".

2) Create a regular button for copying. Add the following JavaScript to the click event of the button:

textValue.value = TextField5.rawValue;

3) Create a regular button for pasting. This is where it is tricky. You can use an easy script to just populate a field value like:

TextField6.rawValue = textValue.value;

But I can't paste in notepad

almitche
Expert
Registered: Apr 1 2008
Posts: 41
Hi smilem,

I looked into this a little further, but no luck. One thought was to use Acrobat's execMenuItem() method to call the Copy functionality from the hosting Application (Acrobat/Reader), but that action is restricted, it seems due to security considerations.

I was trying to do this:

app.execMenuItem("Copy");

I can't find any other way to perform the action you describe.

Apologies.
smilem
Registered: Apr 1 2008
Posts: 101
almitche wrote:
Hi smilem,I looked into this a little further, but no luck. One thought was to use Acrobat's execMenuItem() method to call the Copy functionality from the hosting Application (Acrobat/Reader), but that action is restricted, it seems due to security considerations.

I was trying to do this:

app.execMenuItem("Copy");

I can't find any other way to perform the action you describe.

Apologies.
Perhaps there is a way to override this? Security settings?