Defining Groups of Elements in XML Schemas - Diagram View

To define a group of elements:
2. Right-click the schema node .
3. In the shortcut menu, select Add > Group.

Alternatives: This operation is also available from the XMLSchema > Diagram > Add > Group menu and from the Add button .

The new group is added to the XML Schema. It is displayed in the diagram and in the text pane (if you have it open). The properties for the new group are displayed in the Properties window.

4. Specify the group name in the Name property in the Properties window.
5. Right-click the new group.
6. In the shortcut menu, select Add > and then select the modifier for the group of elements - All, Choice, or Sequence. In the Properties window, click the fields for the Min Occur. and Max Occur. properties to specify their values. These properties determine how often the group of the elements with the selected modifier can appear.
7. Drag the elements defined in step 1 and drop them on the all, choice, or sequence modifier created in step 6.

Alternative

If you prefer, you can create the element group first, define the modifier for the group elements, and then add new elements to the group by right-clicking on the modifier and selecting Add > Element. If you do this, you must then define each of the elements you added to the group.

 
Free Stylus Studio XML Training: