From the course: Access 2016: Forms and Reports

Set the default properties for objects

From the course: Access 2016: Forms and Reports

Start my 1-month free trial

Set the default properties for objects

- [Voiceover] Sometimes you'll find yourself making the same design changes over and over again when it comes to adding controls to your forms and reports. You could alter the default properties of your form controls in order to keep everything consistent and speed up development time. Let me show you how to do that by taking a look inside of our control form that we created earlier. I'll open it up into design view. Let's start by adding in a new label control. I'll click on this one here in the controls group, and come down here and click, and I'll just type in the word text. If I switch over to the format tab, we can see that this text box is calibrated at 11-point, and it's this kind of gray color. If I wanted to change the styling, I'll just double-click on it, and then come up here into the font group, and change the font to Cambria. I can also change the size to 14-point, and change the color here to black. But now if I go over to the design tab and add in a new label, go ahead and type that in, and I'll type text, you'll see that the styling gets reverted back to its original state. Now if I wanted this text to be the default option, what I can do is click to add a new label, but don't add one down into the detail section of your form. Instead, take a look over here on the Properties Sheet, and you'll see that the selection type currently says, Default Label. If we change the Properties now, it's going to change those defaults for each label. Let's go down and change the font name here from Calibri to Cambria. I'll change the font size to 14-point, and we'll change the color, here, which is going to be the fore color property, and I'll change it to be automatic, which will be black. Now let's go ahead and click here, and I'll type in the word text, and we can see that it gets those properties. Now this doesn't just apply to label controls. We can actually do the same thing with all the different controls here in the design tab of the ribbon. Earlier in the course, I mentioned that my favorite style for this button was to have the Use Theme property set to no. If I want to set that as the default property, I could just go ahead and change it now, and then when I click to add a button and press cancel to get out of the command button wizard, you'll see that it gets that default gray appearance. Unfortunately, the defaults only apply to this specific form, so if you create a new form, objects will return to their original defaults. You can save yourself a little bit of time by preparing a saving a starting form design that you copy when you want a new object, rather than starting from scratch each time. So that's how default properties are established for your form controls. By taking a few minutes up front to set them, you can save yourself countless number of clicks down the road.

Contents