If you want to track information with your drawings, you probably also want to customize the shape data. Perhaps your company uses a specific nomenclature for fields that you want your drawing to reflect. Or maybe you want to remove some shape data to streamline data entry. You can add and remove shape data as well as edit their labels and the format used to display the values. Visio 2007 features two ways of accessing shape data:
Through the Shape Data window, which lets you work with the properties of a single shape or master shape.
By editing shape data, which is described later in this chapter. This lets you define multiple properties at once (that is, a shape data set), which can be applied to multiple shapes at once.
Whether you work with individual shapes in the Shape Data window or create shape data, you will encounter the Define Shape Data dialog box, as Figure 6-10 shows. Working with this dialog box can be a little tricky, because as soon as you specify an option, it’s applied to the data.
The options in this dialog box let you define the data that appear in the Shape Data window, as Table 6-2 shows. If you’re working with a shape that already has shape data, the existing data are listed at the bottom of the Define Shape Data dialog box in the Properties pane. When a property is selected in this box, the dialog box displays its definition in the fields on top, so if you make changes to one of the options, the change is immediately reflected in the shape data’s definition.
Option | What It Does |
---|---|
Label | Provides the name of the property as you want it to appear in the Shape Data window. |
Type | Lists Visio 2007 data types that you can specify for a value. If you aren’t sure what to choose, select String. |
Format | Specifies a format for the type of data. The options change depending on the type you select. Not all property types have formats that you can choose. When you select an option, a format code appears in the Format box that tells Visio 2007 how to display the property’s value. |
Value | Shows the current value of the data or lets you set an initial value for new data. If you leave it blank, an empty field is displayed in the Shape Data window. |
Prompt | Provides an instructional or descriptive prompt about the property. Prompts are optional, but they’re useful for describing the purpose of the shape data. Your prompt text appears as a ScreenTip in the Shape Data window or in the Prompt area of a shape’s Define Shape Data dialog box. |
Properties | Lists the shape data that are already defined for a shape. If you select a property from the list, you can then change the Label, Type, Format, Value, and Prompt settings, and your changes are immediately applied to the shape data definition. |
New | Creates new shape data and initializes the Label, Type, Format, Value, and Prompt options so that you can define the new property. |
Delete | Deletes the shape data selected in the Properties pane. |
If you really want to revise the shape data for one shape in one drawing, you can do so. You can edit shape data directly in the Shape Data window or Shape Data dialog box without affecting any shape data sets that have been defined for the shapes. The changes you make are saved only with the drawing. If the shape is based on a master shape, your changes to the shape do not affect the master or any other instances of the master you’ve dragged onto the drawing page.
To add or edit shape data for one shape, follow these steps:
1. | Select a shape on the drawing page. |
2. | If the Shape Data window is not already open, choose View, Shape Data Window. |
3. | If no data have been defined for the shape, you will see a message to that effect in the Shape Data window. |
4. | Right-click anywhere in the Shape Data window, and then choose Define Shape Data.
|
5. | If the shape already includes shape data, in the Properties pane, select the property you want to edit, or click New. |
6. | When you select an existing property, its settings are displayed in the dialog box. As soon as you change a setting, the new specifications are applied to the selected property. |
7. | Define the new data, or revise the selected data, by typing or selecting the values you want for Label, Type, Format, Value, and Prompt. For details about these options, see Table 6-2. |
8. | When you’ve defined the data, do one of the following:
|
One time when it is handy to add or edit an individual shape’s shape data is when you’re working in a custom stencil. You might apply a set of shape data to all the shapes in the stencil and then edit a particular master shape in the custom stencil to customize its data. The procedure is basically the same as the process for a shape on the drawing page. The difference is in the first couple of steps, in which you open a custom stencil and edit a master.
Note
You cannot edit the master shapes on the stencils. To edit a master you must first right-click the master and then save it to My Shapes or any other custom stencil that you have created. To create a stencil, choose File, Shapes, New Stencil. No fuss, extremely little muss.
To add or edit shape data for a master shape on a custom stencil, follow these steps:
1. | Open the custom stencil containing the master shape you want to edit by doing one of the following:
|
2. | Right-click a master shape in the stencil, and then choose Edit Master to open the shape in a new drawing window. |
3. | If the Shape Data window is not already open, choose View, Shape Data Window. |
4. | Select the master shape. If the shape includes shape data, they are displayed in the Shape Data window. Otherwise, Visio 2007 displays the “No Shape Data” message in the window. |
5. | Right-click anywhere in the Shape Data window, and then choose Define Properties. |
6. | Select the property you want to edit, or click New. When you select an existing property, its settings are displayed in the dialog box. As soon as you change a setting, it’s applied to the selected property. |
7. | Define the new property, or revise the selected property, by typing or selecting the values you want for Label, Type, Format, Value, and Prompt. For details about these options, see Table 6-2, earlier in the chapter. |
8. | When you’ve defined the property, do one of the following:
If you edited the document stencil, the message differs slightly.
|
9. | Click Yes. If you edited a document stencil, all the shapes in the drawing that are based on the master shape you edited will include the revised shape data. You can save your changes by doing either of the following:
|