Add data to shapes

Shapes on a Visio diagram can hold data. When you select a shape, the data is shown in the Shape Data window. This is useful for providing details, for example about steps in a process or pieces of equipment in a network diagram, without filling up the main diagram with text.

In Visio Professional, you can also link shapes to data in an external data source.

Add data to selected shapes

To add data to shapes that are already in your drawing, first add the data fields to your shapes and then add values.

Add data fields to selected shapes

  1. On the View tab, in the Show group, click Task Panes, and then click Shape Data.
    The Shape Data window opens.
  2. Select the shape or shapes that you want to add data to.
  3. Right-click the selection, point to Data on the shortcut menu, and then click Define Shape Data.
  4. In the Define Shape Data dialog box, click New, and then do the following:
  • In the Label box, type a name for the new field.
  • In the Type list, select a type of data for the new field to contain.
  • In the Format list, select a format for displaying the data. The format options change depending on the chosen data type.
  • If you want to provide a text prompt for someone adding data to the field, in the Prompt box, enter the text that you want. The text appears when the mouse pointer is held over the field in the Shape Data window.
  1. Click OK.

Add values to your data fields

  • Select each shape one at a time, and type the values into the data fields in the Shape Data window.

The contents of the Shape Data window show the data for the selected shape only.

Create a reusable set of data fields

You don’t have to create data fields for each shape individually – you can create a set of data fields and apply it to all selected shapes in your drawing, and to shapes that you place in the drawing later.

  1. On the View tab, in the Show group, click Task Panes, and then click Shape Data.
    The Shape Data window opens.
  2. Right-click anywhere in the Shape Data window, and then click Shape Data Sets.
  3. In the Shape Data Sets window, click Add.
  4. In the Add Shape Data Set dialog box, type a name for the data set.
  5. Select Create a new set, and then click OK.
    The data set appears in the Name column of the Shape Data Sets window.
  6. Select your new data set, and then click Define.
  7. In the Define Shape Data dialog box, define the fields for your shape data set.
  8. To create another field, click New.
  9. After all of your data fields are defined, click OK.
  10. To apply the data set to selected shapes in your drawing, select the set in the Shape Data Sets window, and then click Apply.

To see your new fields in one of the shapes that you applied it to, select the shape, and then look in the Shape Data window.

Add data fields to a master shape

If you want to add the same set of shape data every time you use a particular shape, you can save time by adding the data fields to a copy of the master shape (master shape: A shape on a stencil that you use repeatedly to create drawings. When you drag a shape from a stencil onto the drawing page, the shape becomes an instance of that master.). For example, you can add data fields such as name and employee number to the master of a person shape.

Create a copy of the shape on a custom stencil

  1. In the Shapes window, right-click the master shape, point to Add to My Shapes, and then do one of the following:
  • If you want to add the master shape to a new stencil, click Add To New Stencil.
  • If you want to add the master shape to an existing custom stencil, click Add To Existing Stencil.
  1. In the Save As dialog box, type a name for the new stencil, and then click Save.
  2. In the Shapes window, click More Shapes, point to My Shapes, and then click the stencil that contains the copied master shape.

Edit the new master on the custom stencil

  1. Right-click the title bar of the new stencil, and then click Edit Stencil on the shortcut menu.
  2. Right-click the shape that you just added to the stencil, point to Edit Master, and then click Edit Master Shape.
  3. In the shape’s edit window, right-click the shape, point to Data, and then click Define Shape Data.
  4. In the Define Shape Data dialog box, type a name for the field, and fill in any other information that you want. For example, you might want to change the data type or add a shape prompt at this time.
  5. To create another field, click New and repeat the previous step.
  6. After you finish defining your data fields, click OK.
  7. To close the master shape’s edit window, on the View tab, in the Window group, click Cascade, select the window for the master shape, and then click the Close button (X) in the upper corner.
  8. When you see a message that asks if you want to update the shape, click Yes.
  9. In the Shapes window, right-click the stencil, and then click Save.

Delete a data field

  1. Select the shape that has the data field that you want to delete.
  2. Right-click anywhere in the Shape Data window and click Define Shape Data.
  3. In the Define Shape Data dialog box, under Properties, select the data field that you want to delete, click Delete, and then click OK.
 
 
Maikakapit sa:
Visio 2013, Visio Professional 2013