July 27 2009 • 9:35 AM

PDF Button Tips, Tricks and Problem Solving

As I said in my previous posting about creating buttons in InDesign CS4, buttons are now easier to create. But there are some critical features which aren’t obvious, especially when you’re new to creating buttons. In this posting, I’ll focus on creating buttons for interactive PDF files in CS4. And there will inevitably be problems along the way, so you need to know something about troubleshooting problems. This means learning a little about buttons in Acrobat. (By the way, most of these tips also apply to creating buttons in InDesign CS2 and CS3 as well.)

Tips and Tricks for Creating PDF Buttons

The following list isn’t exhaustive, but, no doubt, those reading it can suggest some other tips:

1. When possible, create buttons on master pages in a document. This will greatly reduce the number of buttons you need to create, and will ensure consistency.

2. Buttons can have different attributes for visibility and printability. In the PDF language, buttons are considered a kind of field (think form fields). Fields can have four variations of visibility—Visible in the PDF, Visible in PDF but Doesn’t Print, Hidden in PDF, and Hidden in PDF but Printable. You can choose which of these attributes are applied to a button from the Button panel menu. Most buttons are Visible in the PDF but each of these options has their uses.  (Example: If you want a picture to appear when you click a button, create two buttons. Place the picture in a Hidden button, and use the Show/Hide Button action in the Visible button to make the picture visible.)

Button Panel menu

3. Buttons only “come alive” in an interactive PDF file if you turn on the right options when you export your PDF. (Forget trying to create a PDF using Distiller; that kills everything.) In the Export PDF dialog, be sure to check Interactive Elements (and also check Hyperlinks if you’re using those in your interactive PDF file).

PDF Export options

4. If you’re using transparency in your document and it in anyway interacts with a button, you must save your file with Acrobat 5 compatibility or higher (no transparency flattening). Otherwise, you’ll get the message below, and you’ll lose your interactivity:

Choose Acrobat 5 or later

Creating a Go to Page Button in a PDF File

As I mentioned in the previous posting, there is a Go to Page action in the Button panel in InDesign CS4, but it’s only for creating buttons to be exported as a SWF file. So how do you create one in a PDF file? You need to create a text anchor, and use the Go to Anchor action. (As we’ll see, these have a different name—named destinations—in Acrobat.) Here’s how to do it:

1. Go to the destination page, and select text in a text frame. (You could make text Paper color to hide it if you don’t want it to be visible.)

2. Open the Hyperlinks panel (Window > Interactive > Hyperlinks). Choose New Hyperlink Destination from the panel menu. By default, it names the text anchor it creates using the text string you selected, although you could rename it.

Create Text Anchor

3. Make a button, and make its action Go to Text Anchor. Select the text anchor you created.

Select Text Anchor

When an interactive PDF is created, that should create a named destination that the button will select, jumping to the appropriate page.

Button Troubleshooting in Acrobat

We’d expect that all the buttons we create in InDesign would create perfect buttons in Acrobat. Unfortunately, many things can go wrong. In fact, as I was preparing this posting, I ran into one myself. So I’ll use it as an example of how to troubleshoot buttons in Acrobat. When I created a text anchor as I described above and made a PDF, all my buttons worked correctly except that one. As of this writing, I’m not sure what happened (my colleague and friend Sandee Cohen wasn’t able to replicate the problem). I did the requisite troubleshooting (like restoring my InDesign preferences) but the problem persisted. The method worked correctly in InDesign CS3 so it could be a subtle InDesign CS4 bug.

I opened up Acrobat to see what was going wrong. Acrobat has had its own interface for creating and editing buttons for many versions. In many ways, it can create buttons which are more complex than those that can be created in InDesign so it’s worthwhile to learn how it works.

I worked in Acrobat 9 Pro which now has a special form editing mode, and I’ll give the steps I followed, but I’ll also describe how I could use Acrobat 8 Professional as well. I ended up editing the named destination (text anchor).

1. Choose Forms > Add or Edit Fields (In Acrobat 8 Pro, choose Forms > Edit Form in Acrobat.)

2. Find the button which is not working. You can use the Fields panel at the left to help identify it, if necessary. Double-click the button. (In Acrobat 8 Pro, the Forms toolbar opens. Click the Button tool, and double-click the problem button.)

3. The Button Properties dialog box opens. Click the Actions tab.

Acrobat 9 Button Properties

4. In the Actions section at the bottom, select Go to a page in this document. Click the Edit button.

Editing the Named Destination

Now you can see that the text anchor (now called a Named Destination) is embedded in the PDF file. Browse to reselect it again, and click OK.

5. Close the dialogs. Click Close Form Editing (Acrobat 9 Pro only).

After reselecting the destination, the button worked fine.

What if you needed to create a new destination in Acrobat? You’d use Acrobat’s Destinations panel. Here’s how:

1. Choose View > Navigation Panels > Destinations

2. Navigate to the page you’d like to make the destination.

3. Choose New Destination from the Action popup menu (gear icon).

Acrobat Destination Panel

A new destination is created. You’re given the opportunity to name it. It’s set to the page you’re currently viewing.

4. Edit your button to select the new destination you created.

Good luck on your button creation, and post your own tips for working with buttons in the comments.

23 Responses discussing this post. Add yours below.

  1. David Blatner
    July 27th, 2009 • 3:52 pm • Link

    These are great tricks, Steve. Thank you for sharing them. Making buttons is not always as straightforward as one would hope.

  2. July 28th, 2009 • 5:06 pm • Link

    Hey, thanks. Now I know how to fix the my document. I was pulling my hair out.

  3. Vlad B
    August 19th, 2009 • 9:40 am • Link

    my problem is a little different ….. but close to what you are talking about….

    when i export the Interactive PDF i see all the pages, but all i need to see is the one FRONT page with all the hyperlinks

    i mad couple of PDFs and they worked fine but for some reason i cant do it now…. what im getting now is all the pages VISIBLE

    Please Help

  4. Steve Werner
    August 19th, 2009 • 9:50 am • Link

    Vlad,

    It’s a little unclear to me what you want to do. You have a multipage document with links on the first page to the other pages in the same document? But in the PDF you only want to see the first page? What is it that you want to happen when you click a link?…I’m not sure this is possible.

  5. September 10th, 2009 • 4:01 pm • Link

    you guys are great, why nobody teach this things in the school, i learn more with you rather at school.
    i appreciate your effort and thank you.
    i am on bussiness because of you.

  6. Kelli
    November 12th, 2009 • 7:37 am • Link

    I’m using CS4 to create an interactive PDF brochure. I have my buttons set on the master page (and I’ve successfully done this before) but once the PDF is exported, the text on the buttons (ie: Home, etc…) won’t show up and the button is blank.

    Do you know why this is? Is there anything I can do, or is this another CS4 bug?

    Any help you could provide would help a lot.
    Thank you!

  7. Kelli
    November 12th, 2009 • 7:44 am • Link

    Another question:

    I’m linking a button to a file (a PDF form) but want the user to be able to go back to the interactive PDF. Is it possible to open this file in another window?

  8. Mike Rankin
    November 12th, 2009 • 11:28 am • Link

    Kelli-

    If I understand your question, I don’t think there’s a way to specify a target window for the link to open in (either in InDesign or Acrobat). It’s something I’ve wanted to do too. Would make a good feature request.

  9. Judy
    December 6th, 2009 • 3:35 pm • Link

    Thanks for all your tips. I’m really struggling with the “layering” of buttons and pop-ups. I have photos on a page that each require their own “More Info” button which when selected shows a “pop-up” screen. These screens are overlapping other photos and in some cases the “pop-up” screen falls BELOW the “More Info” button of another photo so is interfering with the “pop-up” screen.

    I’ve tried putting the “More Info” buttons on a separate layer below the layer of Pop-ups, but this makes it worse. On my screen all of the “More Info” buttons are beneath all the pop-ups but that’s not what’s happening in Acrobat. Do you have any ideas on how to make this work properly?

  10. Judy
    December 6th, 2009 • 3:36 pm • Link

    Hi there….I had my e-mail wrong in the previous comment (about layering Pop-ups and More Info buttons). This comment has the correct e-mail address.

  11. David Blatner
    December 6th, 2009 • 9:03 pm • Link

    Judy: These kinds of complicated button situations are very hard to manage in InDesign… well, it’s more that they’re hard to manage in Acrobat — which has a very limited ability to deal with buttons. I would try very, very hard not to overlap buttons.

  12. ty
    February 25th, 2010 • 3:52 pm • Link

    I want to show/hide a Table of Contents “button” with multiple buttons embedded in it to go to any page – like a dropdown menu. Only in PDF – using InDesign. Is this even possible yet?

  13. March 17th, 2010 • 9:15 am • Link

    First sliced bread, then anchor text. It’s a good life. Thanks. Saved hours with this one.

  14. March 22nd, 2010 • 8:29 am • Link

    Hi Steve

    funny enough I ran into the same problem as you on your ‘This week’s…” button.
    Luckily it was quite obvious to spot for me, as 5 out of many buttons did not work; they all had either quotation marks or, like in your case, apostrophies in the text anchor.
    Just leave these characters out of the selection and it will work.

  15. iñaki
    April 21st, 2010 • 8:33 am • Link

    I would like to add an action to one of the buttons i’ve created. Their are multiple choice solutions as we can see in the article, but i would like to create a button or an action that pressing on it you print the document or pop ups the printer options. I know it is possible because i’ve got a presentation in wich this button exists but i have it in PDF so i can’t see the source.
    Thanks a lot!

  16. April 21st, 2010 • 8:53 am • Link

    inaki, you can see how it’s done in Acrobat Pro. Select the Arrow tool (from the Advanced Editing toolbar) and all buttons on the PDF page get an outline and handles. Double-click on the button with that Arrow tool, and the button’s Properties Inspector dialog box opens. Choose the Actions panel in the dialog box to see what the button does.

    You can’t use InDesign to create the type of button action you describe. If you want a button in a PDF to do something from Reader’s or Acrobat’s menu (like File > Print), you need to set up that button in Acrobat, then for the Action, choose Execute a Menu Item, and finally choose the menu item you want the button click to do.

  17. iñaki
    April 23rd, 2010 • 2:00 am • Link

    Thanks Anne Marie, it’s a little bit annoying that a wonderfull aplication like Indesign CS4 does not have this option.

    Thanks anyway

  18. elizabeth
    October 4th, 2010 • 8:49 pm • Link

    I wanted to set up an action for “print” as well in indesign in my master pages.
    Since it seems I have to resort to acrobat to do so, is there a way to apply the action to all pages (36 and counting) instead of copying and pasting link on every page? Everytime the client makes a change I have to do it all over again!!! Please help.

  19. October 5th, 2010 • 5:21 am • Link

    @elizabeth: You definitely want to read this post on the Replace Pages feature in Acrobat.

  20. West
    March 18th, 2011 • 7:38 am • Link

    I am able to make buttons and embed a movie in PDF and it works fine in PDF after I export it but does not work after I email the PDF. Please advise. Indesign C2

  21. West
    March 18th, 2011 • 7:39 am • Link

    Indesign CS2

  22. citizenbobx
    December 1st, 2011 • 2:28 pm • Link

    I’m using CS5 to generate an interactive pdf, setting up text buttons to navigate to the network of text anchors I created, and have encountered the same problem. The buttons no longer advance to certain text anchors in the exported pdf and there appears to be no rhyme or reason as to why. Some work, some don’t. Some that used to work, stop working. Very frustrating.

  23. DAVID
    March 16th, 2012 • 6:25 am • Link

    WONDERFUL EXPLANATION AND HELPED ME LOADS. THANKS VERY MUCH
    DAVID

Subscribe to the Discussion

Get the ongoing discussion surrounding "PDF Button Tips, Tricks and Problem Solving" delivered to you. Click here to subscribe via RSS.

Leave a Reply

You can use limited HTML tags, such as <em></em> for emphasis/italics and <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> .

InDesignSecrets reserves the right to edit and/or remove posts and comments.