Join David Blatner for an in-depth discussion in this video Adding text and list fields, part of InDesign: Interactive PDFs.
- [Instructor] We have all the makings of a form here, well at least we have the labels. In this case all the labels are in a single text frame, some people put them in individual frames and other people put them inside of a table. It doesn't really matter how you do it, but it is really helpful to set up the structure of your table where all the labels and the form fields should be before you start adding those interactive form fields. Because while it is pretty easy to move your form fields around later, it's a little bit of a hassle.
So now that I have this set up I now need to add some text entry fields for people to type in their name and email address and things like that. To do that I simply grab a frame, but first I'm going to zoom in on this area. I'll press command space bar or control space bar on Windows, and zoom in on this area. Now I need a frame. You can use any kind of frame in InDesign, I usually use the graphic frame, the one with the Xs in them but you can use unassigned frames or text frames or pretty much any kind of object inside of InDesign.
Here I'll drag out a graphic frame on my page. Now you could fill this with a color if you want, for example I'll fill this with this light pink color. Now I should point out that some PDF readers like Acrobat will place highlighting on top of that pink color, so it may not look exactly the way it looks here. Now here's what turns an ordinary InDesign frame into an editable text field, I need to go to the buttons and forms panel. I have it over here in my dock, but if you don't have it in your dock you can always find it under the window menu, under the interactive sub-menu.
Here inside the buttons and forms panel I'm going to go to the type pop up menu right at the top and I could choose button, we talked about that in an earlier chapter. But in this case I'm going to choose text field all the way down here at the bottom of the list. That's it, now this will be a text field when I export it to PDF. But before I move on I'm going to do a couple of things here. First, it's really important to change the name. Right now text field nine is not very descriptive, so I'm going to change this to first name.
Now technically I could add an event and actions to this text field, so that something would happen when you click in here. But I'm not going to do that, because this is just going to be a regular text field. What I will do however is go down here to the bottom of this panel and I can say PDF options. If you don't see these options, click this little triangle on the left side. Now the first thing I'll do is give this a description. This description shows up as a tool tip. In other words, if somebody hovers over this field it can give them instructions about what to do.
So I'll just type, type your name, that sounds pretty good. You'll see that you also have some options down here for this text field. For example, will this print, is it required? Yes I'm going to make this required because I want to make sure they type in their name. I could turn on the password checkbox and then Acrobat would actually hide what I was typing, but that wouldn't be helpful here. Over here you also have some options like read only, it's pretty rare that you'd need read only for a text entry field.
Multi-line is helpful though because sometimes you'll have a large entry field, something like a comment and you might want to have multiple lines, not just one. So in that case you'd turn this checkbox on. Finally, scrollable, that is if someone does put a lot of text in here, so much that it actually fills the frame, will it turn into a scrollable field or will it just clip it off? I generally leave the scrollable checkbox on. Finally, we can change the font size down here.
I'll just leave that set to 12 points right now. What you cannot do is set the default font or any other default text that you want in there. Let's say you want to have some sample text that somebody might want to type, you can't do that in InDesign, you'd have to do that in Acrobat later. Actually there is a commercial script called Form Magic from IDExtras.com, and that can really help with formatting text entry fields. So anyway, in this case we have our name field and now we want another one for address.
To get that I'm just going to select this object with a selection tool, hold down the option and shift or alt shift on Windows, and then drag down. That creates a duplicate of that frame. In this case I'll also extend the left edge of this a little bit. Now the first thing I'm going to do inside the buttons and forms field, is change the name. I'll change this to address field. Then I'm going to turn off the required checkbox. And I'll go ahead and change the description down here as well.
Your address please. Now sometimes you want to give your audience some items to choose from, instead of just letting them type in stuff for themselves. That's where list boxes and combo boxes come in. Let's add one down here. Once again I'll simply drag out a frame, in this case next to the state field. Then I'll fill it with a color again, just to make it consistent. Now to turn it into a list box or a combo box I'm going to go to the type pop up menu inside the buttons and forms panel, and I'll choose one of those items here.
Now I should explain the difference between a combo box and a list box. Both options let your audience choose from a list, a combo box is what I call a pop up menu, kind of like this type pop up menu that I'm in right now. This is a type of combo box, in a combo box you can only choose a single item. In a list box however, you can see a list of items and you can choose one or more of the items in that list. In this case I'm just going to choose combo box. Now whichever one you choose, you get the same basic user interface down here.
You have all the PDF options that we just talked about, but you also get this list item section. Now I'm going to let the person that's looking at this form pick from New York, New Jersey or Connecticut. I only want them to choose one of those. To add those items to my list I click inside the list items field here, and then type the first item. Then click the plus button to add it to the list down here. Let's do the next one. And finally, Connecticut.
Now all three of these items will show up in my list, or I should say combo box or pop up menu, whatever you want to call it. But I should point out that you cannot preview any kind of form fields inside of InDesign, you have to export them out and look at them in Acrobat. So let's go ahead and do that. I'll go to the file menu and choose export. Now I'll make sure that Adobe PDF Interactive is selected in the format pop up menu, and then click save. In this case I'm going to use the same settings inside this dialog box that I've been using all along, but I'm only going to export this one page.
That'll just speed things up a little bit. Then when I save this, InDesign exports the PDF to disk and opens it in Acrobat. There we go, there are the two text entry fields that we created and the first one, first name, is highlighted in red because it's a required field. But I can click in here and just type my name. Down here, here's our combo box. You see a little triangle indicating that I can click on that to open up the list. And there are the three states that I added.
So this is terrific, but in the next movie we'll add two new types of fields, checkboxes and radio buttons.
- Exporting interactive PDFs
- Inserting hyperlinks, bookmarks, and buttons
- Building interactive forms
- Adding text and list fields
- Adding multimedia such as sound and video
- Creating page transitions
- Working with animations and Flash