Previous Topic: Arrays with Indexed ValuesNext Topic: Modify a Dataset


Define a ValueMap as an Array

You can create a ValueMap, define its variables, and can include arrays in the ValueMap. You can even decide to define a ValueMap as an array. Each variable of the ValueMap represents a structure that you define in the dataset under Element Type.

  1. Click the Library tab.
  2. Select a folder and locate a dataset. Use the optional search features or create a dataset if necessary.
  3. Double-click the dataset.

    The Dataset tab of the Dataset dialog appears.

  4. Click Check Out.
  5. Select a page. The default page is named Parameters.
  6. In the toolbar, click Add Variable.
  7. On the General tab:
    1. Set the Type to ValueMap.
    2. Do not click the Array check box.
  8. Expand the new ValueMap variable and select a page. The default page is named Parameters.
  9. In the toolbar, click Add Variable.
  10. On the General tab:
    1. Set the Type.
    2. Enter an initial value.
    3. Check the Array check box.
  11. Repeat the last three steps. Select a page, click Add Variable, and define the variable as an Array.
  12. Expand the ValueMap variable and page. Right-click the first variable and choose Add Indexed Value.
  13. Repeat the last step.
  14. Right-click the second variable and choose Add Indexed Value.
  15. Repeat the last step.

    You have defined a ValueMap made up of two arrays.

  16. Click the original ValueMap variable.
  17. On the General tab, check the Array check box.

    The Element Type folder appears under the ValueMap variable.

  18. Expand Element Type completely to view its pages, variables, and indexed values.
  19. Right-click the original ValueMap variable and choose Add Index Value.

    Array index [0] appears.

  20. Expand array index [0]. The pages, variables, and indexed values are copied from the Element Type structure.

When you add a variable to a page under Element Type, all existing valuemap array index entries immediately include the new variable under the corresponding page.

When you delete a variable from a page under Element Type, all existing valuemap array index entries no longer include the deleted variable under the corresponding page.

When you specify values for the variables under Element Type, the values become the default values for any new indexed entries of the ValueMap array. The new Element Type values are not propagated to existing index entries of the ValueMap array.