Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member
We have our form all laid out, so it looks good. It's well structured, and now we're ready to begin adding Content Controls. So this is the first thing that we really need the Developer tab for. We're going to click here, and again, we'll use the controls here in this Control group. There are a total of seven of them, and we'll be using six of them in this chapter. So I'm going to start by using Text Controls. There are two different types. This Text Control that is a little bit more formatted is the Rich Text Control. You'll use the Rich Text Control under very specific circumstances.
For example, you'll use the Rich Text Control when you want somebody to provide information that they might want to format differently. They might want some of it to be bold but some of it not to be, or some to be Italicized and other parts not to be, or when the text that you're using would be more than a paragraph, or when you'd like them to be able to include something like a table inside of the content that they're providing, or you'd like them to be able to number or provide a bulleted list here.
Other than that, you can pretty much use the Plain Text Control all the time. That way, your users don't spend a whole lot of time wondering what they can format. So we want someone to enter a first name here. We're simply going to click and drop a Text Control in there that says Click here to enter text. That's the prompt that they'll see. Let's take a look and see what we can do to this particular Text Control. I'm going to click Design mode and you'll notice that it changes the way this looks. When we're not in Design mode, it simply looks like a container of some kind, and when we click it, we can select the whole thing.
But in Design mode, it's very clear that it has a Start and a Finish, and these are called Tags. The data that will be entered in here will be stored as XML. XML stands for Extensible Markup Language, and it's a way to provide easy-to-understand data about your data. For example, we would call this a first name field and because we call it first name, that data about the data, metadata helps describe this if we want to use this data somewhere else. We'll do that in this Properties dialog box.
I'm simply going to click Properties with the Control selected, and I have the opportunity to add two different things; one is a Title. This is a title that you will see when you're in Design view that sometimes appears to users but not all that often, and it can be upper and lowercase and contain spaces. So I'm simply going to put First Name. This Tag on the other hand is the tag for the XML, and we'll be using this later on in some other forms. So you might want to know a little bit about how tags are created. First, by tradition, they're all lowercase and there's no spaces in them.
Now we could provide a particular style to format the contents of this Control, not to format the Control itself or the text that's in it now but once someone has actually typed data into here, we could say well, we'd like this to be a Heading, for example. And we'll have access to the different styles that are available to us here in Microsoft Word, including creating a new style, so that once someone has entered text, it bolds it, for example. A lot of work to go to, but sometimes you want to be able to do that. I want to lock this Content Control so that it cannot be deleted.
Someone can leave it blank, but I don't want them to delete it because that begins to change my form. "Contents cannot be edited" is something you would turn on in a control if you were providing read-only information. Typically, if you were going to do that, you might as well simply just type it in as text as we did Name and E-Mail and Department. However, there's a way that you can unlock this kind of a Control and change its value programmatically using code, and that's why this is here. I'm now going to say OK. It has firstname, there's my title, here are my tags, and if I switch out of Design mode, you'll notice that I really still only see the title here on the Developer tab.
Let's go back into Design mode, and let's add a few other fields that we need to have. Now notice that it's a little weird to be looking at this now, because our table doesn't have gridlines. So if we go back and we say well, I'd like to see some gridlines, it'll help us see the kinds of choices that we're making. And again, note that when I switch out of Design mode, this fits in here on two lines, two rows. If I wanted, I could start making some adjustments now that I know more about my data. Let's say, you know I'd like to actually give it a little more room. The other choice we can make though, which is a better choice, is to enter Design mode and to carefully select the text here.
It doesn't need to say Click here to enter text, it could actually say instead Enter First Name. Now, if I do that, when I switch out of Design mode, it actually all fits right there. In a similar way, I'm going to go in and we're going to add another Plain Text Control, and we're going to say that we would like to have the user Enter Last Name, and it will fit again fairly nicely. Two lines when I'm out of Design mode, we could give this a little bit more room.
So we'll slide this over a bit because we have lots of running room over here, and slide this over. Now the other thing is I have a pretty big font being used in these controls and that's because when I go back to my Home tab, it's using the Times New Roman and elsewhere I'm using Calibri. If I use Calibri instead, then it's going to look better, and I can actually select my entire document or select from here on down and say, I'd really rather use the Calibri font on everything.
But the reason that this is coming up in Times New Roman is that Times New Roman is the font being used here for Normal. So I can take advantage of my styles by selecting something that's in this Calibri 10, right-click and Update Normal to Match Selection. Now, the next textbox that I place comes in in Calibri. So here's my Email textbox, I can change its properties. This is E-Mail, lowercase email for my Tag, can't be edited, say OK.
Then I can go in here in Design mode, I can say Click here to enter email address or I can just say Enter email address. Likewise, my user will enter an Extension here, so we can simply drop this field in and say Enter extension, and go back out of Design mode. Now when my user is using this form as they type somewhere, they can click and they can enter their first name or enter their last name.
Notice that Spell Check is working. Notice also that my Control is still there, but I now have data in it. And I might wonder, ooh! How do I get rid of that when I was sort of just checking this out? Let's go back to Design mode, and go in ,and simply delete all of the text you typed here that's not a placeholder. Our placeholders are gray; here's this text. I'm going to hit Delete, and then I'm going to simply use the arrow key to move out of that field, and when you do, notice that your prompt comes right back.
So I'm going to delete this, simply arrow out, and my original prompt will come back. I'm going to use a Date Picker Control here and some other controls here, so I don't need to put textboxes in, but I do need to replace this line with a textbox. So let's go ahead and select it and delete it, and then we're going to insert a plain textbox. So I'm going to select just about all of this and start typing, and you'll notice that when I do that, I'm actually entering dark black text; this isn't a placeholder anymore.
So this would be a clue to maybe undo this and go back and start again. As long as I have some of the placeholder here, I'm usually all right. So I can, for example, delete this much of it, and say, enter amount if I wish, or remember, if I need to, I can simply get to the end of it, and then I can delete all of it, arrow out of it, and have my original placeholder back. Notice that there's no space here, it's really hard to click here. That's okay, use the arrow key to jump out of this Content Control, put in the space that's desired.
There are some other fields here where I can put textboxes, Credit Card Number, Expiration Date, Billing Zip Code, name, and these three fields down below. I'm going to go ahead and work on that while you work on your form, and then I'll see you in the next movie and we'll be adding some List Controls.
Get unlimited access to all courses for just $25/month.Become a member
82 Video lessons · 90676 Viewers
80 Video lessons · 137966 Viewers
59 Video lessons · 56738 Viewers
52 Video lessons · 70358 Viewers
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
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.