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

SWF visible but not printable - Is this possible?

alex35.williamson
Registered: Nov 16 2011
Posts: 8

I have an SWF video clip in my PDF. It automatically starts when the document is opened. The problem is that this is a form and i have said which fields i would like to print and those that i don't.
 
When I get to printing the document, the box with the SWF prints the part of the movie that was last playing before I pressed print. I don't want any part of the box to print. I want it to be "visible but doesn't print".
 
Please help,

Thanks, Alex :-D

My Product Information:
Acrobat Pro 10.1, Windows
UVSAR
Expert
Registered: Oct 29 2008
Posts: 1357
It's possible via a number of methods. The simplest to do are as follows:

1) Manually choose a poster image for the annotation that doesn't appear (such as a white square), then add a JavaScript to the "document.willPrint" action, which disables the annotation.

2) Use a Preflight fixup to move all Multimedia annotations to a new layer, then set that layer to be non-printing.



Advantage of (2) is that the SWF can remain activated, so won't lose any settings. Disadvantage is that without some extra work you can't choose which multimedia annotations are promoted to the layer, so it's a global effect on the whole file.
alex35.williamson
Registered: Nov 16 2011
Posts: 8
If i was to use the JavaScript, where would I put "document.willPrint"? In the document itself or somewhere else? - I cant see where it would go otherwise.

Sorry, I'm new to Acrobat! :-D

Thanks, Alex :-D

UVSAR
Expert
Registered: Oct 29 2008
Posts: 1357
Open the Tools Pane, then the JavaScript Panel (it may not be visible, use the context menu on the Pane header to turn it on). Click "Set Document Actions" and you'll find all the event triggers in a list. Pick one and open the editor.

If for example your SWF is on page 3 (JavaScript page 2) and is the only Rich Media annot on that page, in the editor window you would type

getAnnotsRichMedia(2)[0].activated = false;


Note that due to the way Acrobat/Reader generates events, the thumbnail preview on the print dialog will still show the active SWF, but it will be deactivated before the job is sent to the printer (doc.willPrint fires *after* you click the Print button on the dialog, not when the dialog opens).


You could use the doc.didPrint trigger to re-activate the SWF if you wanted to.
alex35.williamson
Registered: Nov 16 2011
Posts: 8
Ok, that's not really working for me. I changed the numbers in the JavaScript because there's only one page, but it's still printing the SWF.

Here is the file i'm working on;

TIMETABLE Template
.
This is the 'poster file' i'd like to have to cover the SWF:

http://sites.google.com/site/062765682files/home/blank.pdf?attredirects=0&d=1
.
Everything that I want to print prints and everything that i don't want to print doesn't print - except the SWF.

Sorry about this!

Thanks, Alex :-D

UVSAR
Expert
Registered: Oct 29 2008
Posts: 1357
Look at my previous post - the second set of brackets are square as they're referring to a member of an array. Yours are both round, so the script won't run.