From the course: Revit: Creating C# Plugins

Unlock the full course today

Join today to access over 22,400 courses taught by industry experts or purchase this course individually.

Tagging elements

Tagging elements

From the course: Revit: Creating C# Plugins

Start my 1-month free trial

Tagging elements

- [Instructor] Now that we know how to create views and apply filters, let's have a look at the next step in developing views which is annotating elements. This is done in the API by using either the IndependentTag class or the RoomTag class. The IndependentTag class is used to create a tag object which can be done with one of two create methods, the first allows us to specify the tag type to use, and the second will use a default tag type, depending on the element that we're tagging. This will be different for doors and windows for example. This method tags quite a few different parameters, including the view to tag in, this can be either 2D or a locked 3D view, we'll also need the element to tag as a reference, a Boolean for whether or not to show the leader, a tag mode which is an enumeration. This can be used to decide whether to tag by category or by material for example, and then tag orientation. This is another enumeration which can be either vertical, or horizontal, and…

Contents