# Creating attributes and attribute lists

You can use an attribute to describe an element or provide information about it. Attribute lists enable you to group together all related attributes for an element.

All elements must have their attributes listed in an attribute list . If you add an attribute to an element that does not already have an attribute list, an attribute list will be created for the element with a new attribute inserted in it.

To create an attribute, follow these steps:

1. Open your DTD in the DTD editor.
2. In the Outline view, right-click the element you want to work with and click Add Attribute. An attribute list will be created for your element if one does not already exist.
3. Select the attribute you just created.
4. In the Properties view, type the name of the attribute in the Name field.
5. From the Type list, select the attribute's type.
6. From Usage list, select the default usage of the attribute. It determines how the attribute can be used.
7. If you selected #FIXED or Default as the default usage of the attribute, you must enter a value in the Default value field.

Related tasks
Deleting elements, attributes, entities, notations, and comments

(C) Copyright IBM Corporation 2000, 2005. All Rights Reserved.