Start learning with our library of video tutorials taught by experts. Get started

InDesign Insider Training: Interactive PDFs

Adding calculations to your PDF files


From:

InDesign Insider Training: Interactive PDFs

with David Blatner

Video: Adding calculations to your PDF files

As I said in the last movie, you just can't do everything in InDesign. One of the most important things that you need Acrobat for is adding advanced functionality to your PDF files. For example, calculation fields. I had my flyer document open for my exercise files, and I'm going to click on this text frame and zoom in 200% by pressing Cmd+ 2, or Ctrl +2 on Windows. You'll notice that I've added a Total field here. And I want this Total field to automatically calculate how expensive these tickets are going to be based on how many tickets the people are going to buy.

Watch this entire course now—plus get access to every course in the library. Each course includes high-quality videos taught by expert instructors.

Become a member
Please wait...
InDesign Insider Training: Interactive PDFs
2h 22m Intermediate Jul 23, 2013 Updated Jan 17, 2014

Viewers: in countries Watching now:

While PDFs can be used for printing, they also have interactive features that make them great for forms, brochures, and prototypes. In this course, InDesign insider David Blatner tells you what interactive PDFs are, why they're so useful, and how to make them yourself with Adobe InDesign and Acrobat. Learn to make hyperlinks to websites, other pages in your document, and email; add buttons that navigate, show, and hide content; create a form with check boxes and text entry fields; and embed audio and video. Plus, discover how to add polish with calculations, page transitions, and more.

Topics include:
  • Creating a new interactive document
  • Linking to URLs and mail addresses
  • Creating bookmarks
  • Adding buttons with rollover states
  • Adding text, list, and submit fields to forms
  • Embedding audio and video
  • Adding page transitions
  • Best practices for exporting high-quality interactive PDF files
Subjects:
Design Digital Publishing PDF
Software:
InDesign
Author:
David Blatner

Adding calculations to your PDF files

As I said in the last movie, you just can't do everything in InDesign. One of the most important things that you need Acrobat for is adding advanced functionality to your PDF files. For example, calculation fields. I had my flyer document open for my exercise files, and I'm going to click on this text frame and zoom in 200% by pressing Cmd+ 2, or Ctrl +2 on Windows. You'll notice that I've added a Total field here. And I want this Total field to automatically calculate how expensive these tickets are going to be based on how many tickets the people are going to buy.

This is just a regular text frame that I've turned into a Text Field button. If I open the buttons and Forms panel, you can see that this is just a Text Field type button. I'm going to make one change here. I'm going to set this to Read Only, because, I don't want my user, the person looking at this pdf to fill this out. I want to calculate it for them. All right, let's go ahead and close that panel and export this PDF. I'll go to the File menu and choose Export. I'll make sure that interactive PDF is selected, since I have form fields and then click Save. I'm going to use the same values that I've been using all along in this title and click OK, and InDesign exports the PDF and then opens it in Acrobat. I find this big purple bar that Acrobat puts at the top of the screen, a little bit annoying, I'm just going to click on the icon on the left, to close it. Then I'll zoom in on this by pressing Cmd+2, or Ctrl+2 on Windows, and then just scroll down a little bit.

Now this field works just the way you'd expect, you can click on the Radio buttons, type in the text fields, and so on. Plus I could come over here and type the number of tickets that I want to purchase. But how am I going to get this field over here to automatically calculate the total? Well, to do that I need to be a little bit sneaky. I'm going to go to the Tools section and I'm going to open up, not my Content Editing, but my Interactive Objects section. Now I'll chose the Select Object tool, which let's me actually select the object those form fields, inside my PDF. I'm going to grab this total over here, and I'm going to duplicate it, and there's various ways to do that.

But the easiest really is just to copy it to the clipboard with a Cmd+ C or a Ctrl + C on windows, and then paste it Cmd+ V or Ctrl+ V. Now I'll move it down here kind of out of the way. Next, I'll right click on this or Ctrl+ click with one button mouse and choose Properties. I'm going to go in here and change the properties for this new field that I've created. First of all, I'm going to change its name. This is going to be called the price of the tickets. Obviously you can call it anything you want. I'm also going to change the form fields from visible to hidden.

I don't want anyone to see this field, it's going to be a secret hidden field in the background. Finally, I'm going to go to the Options tab, and I'm going to say this has a default value of 14. I know it should be 14 because if I move this out of the way, you'll see that the tickets are supposed to be 14 dollars each. Great, now I'll close this and I've set up a hidden field that has the price of the tickets. Now let's change our total field. I'll Right Click on this, or Ctrl+ Click with one button mouse, and Click Properties. The only thing I need to change inside the text field properties for this field, is the Calculate tab. So I'll click on Calculate, and I'm going to tell this field to have a calculation in it.

It's really easy to do. All I need to do is turn on the value is V Radio button, tell it what it's going to be, not going to be a sum. It's going to be a product. It's going to be a multiplication, and it's going to multiply two fields, and I can pick those fields by clicking the Pick button. I want to multiply the number of the tickets by the price of the tickets. Click Ok, click Close and I am done. Now when I go back to the Hand tool as I change the number of tickets here crops down to two tickets.

The total updates updates automatically for me I do wish I had a dollar symbol that would be nice. And we can do that by going back to the Select Object tool right clicking on this and choosing Properties. And then I'm going to change the format of this. I'm going to say the format of this is a number and in fact it should have a currency sign before it. The dollar sign. Click close, and it looks like it's working. Let's go back to the hand tool and we can see I now have a dollar sign and cents after the dollars. Change the number, hit Tab, and it updates automatically.

That wasn't so hard, was it? But there is one problem. What if you later need to go back and make a change to the InDesign document? For example, I just noticed that this says 2012 when it's supposed to say 2014. Oh no! Will all this extra work in Acrobat go to waste? Not at all with the trick that I'm going to show you in the next movie.

Find answers to the most frequently asked questions about InDesign Insider Training: Interactive PDFs.


Expand all | Collapse all
Please wait...
Q: I am trying to turn objects in a layered InDesign document into buttons, following the lessons in Chapter 3, but they don't show up when I export to PDF. What's wrong?
A: This is a known issue with InDesign, stacked layers, and buttons. The final stacking order in your PDF is actually determined by the order the buttons are created, not the stacking order of the layers in your document. David Blatner has researched and proposed a solution to this issue on his InDesign Secrets blog. Read more about it here.
Q: This course was updated on 01/17/2014. What changed?
A: The author updated three movies in the "Links and Bookmarks" chapter, since the behavior of hyperlinks has recently changed in InDesign CC.
Share a link to this course
Please wait... Please wait...
Upgrade to get access to exercise files.

Exercise files video

How to use exercise files.

Learn by watching, listening, and doing, Exercise files are the same files the author uses in the course, so you can download them and follow along Premium memberships include access to all exercise files in the library.
Upgrade now


Exercise files

Exercise files video

How to use exercise files.

For additional information on downloading and using exercise files, watch our instructional video or read the instructions in the FAQ.

This course includes free exercise files, so you can practice while you watch the course. To access all the exercise files in our library, become a Premium Member.

Upgrade now

Are you sure you want to mark all the videos in this course as unwatched?

This will not affect your course history, your reports, or your certificates of completion for this course.


Mark all as unwatched Cancel

Congratulations

You have completed InDesign Insider Training: Interactive PDFs.

Return to your organization's learning portal to continue training, or close this page.


OK
Become a member to add this course to a playlist

Join today and get unlimited access to the entire library of video courses—and create as many playlists as you like.

Get started

Already a member?

Become a member to like this course.

Join today and get unlimited access to the entire library of video courses.

Get started

Already a member?

Exercise files

Learn by watching, listening, and doing! Exercise files are the same files the author uses in the course, so you can download them and follow along. Exercise files are available with all Premium memberships. Learn more

Get started

Already a Premium member?

Exercise files video

How to use exercise files.

Ask a question

Thanks for contacting us.
You’ll hear from our Customer Service team within 24 hours.

Please enter the text shown below:

The classic layout automatically defaults to the latest Flash Player.

To choose a different player, hold the cursor over your name at the top right of any lynda.com page and choose Site preferencesfrom the dropdown menu.

Continue to classic layout Stay on new layout
Welcome to the redesigned course page.

We’ve moved some things around, and now you can



Exercise files

Access exercise files from a button right under the course name.

Mark videos as unwatched

Remove icons showing you already watched videos if you want to start over.

Control your viewing experience

Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.

Interactive transcripts

Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.

Thanks for signing up.

We’ll send you a confirmation email shortly.


Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

Keep up with news, tips, and latest courses with emails from lynda.com.

Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

   
submit Lightbox submit clicked