Referencing Elements

There are more elaborate ways to collect various elements in Revit. This section shows how you can manually reference a specific element and bring that into your Grasshopper definition. Later sections discuss the generic ways of collecting elements of various types.

By Selection

Use the context menu on the Graphical Element parameter to reference geometrical Revit elements in your definition:

By Element Id

You can use the Element parameter and add the element Ids into the Manage Revit Element Collection on the component context menu:


Instances are individual graphical/geometric elements placed in a Revit model e.g. a single Wall, or a single Door, or any other single element. As a subset of Revit Elements, Instances inherit a series of Parameters from their Category and Type and might have instance parameters as well that only belongs to that single instance.

Querying Instance by Type

Use a combination of Model Categories Picker component, connected to ElementType Picker , Type Filter , and Query Elements to query all the instances of a specific type. The example below is collecting all the instance of a Basic Wall type:

Querying Instances by Parameter

You can use the Parameter Filter component in combination with a Filter Rule (e.g. Greater Or Equal Rule or Equals Rule ) to filter elements by their parameter values.

Extracting Instance Geometry

The Element Geometry component can be used to extract the geometry of an instance. In the example below, the complete geometry of a Stacked Wall instance has been extracted. The Detail Level picker can be used to select the level of detail for geometry extraction:

Instance Base Curve

For elements that are constructed on a base curve (e.g. Basic Walls) you can use the Element Curve to get and set the base curve.

Instance Bounding Box

You can pass an instance into a Grasshopper Box component to extract the bounding box of the geometry very easily:

Instance Bounding Geometry

Currently, Bounding Geometry component only works with Walls but will be extended to work with other Revit categories in the future.

Sometimes it is necessary to extract the Bounding Geometry of an instance. Bounding Geometry is a geometry that wraps the instance geometry as close as possible and generally follows the instance geometry topology. You can use the Element Bounding Geometry component to extract this geometry. In the example below, the bounding geometry of a Stacked Wall is extracted. Notice that the bounding geometry is as thick as the thickest part of the Stacked Wall:

Changing Instance Type

Use the Element Type component to both query the Type of an instance, and to change it to another type.

Placing Instances of Types

Use the Add Component (Location) component to place an instance of a Type into the Revit model space.

For types that require a host, you can pass a host element to the Add Component (Location) component as well.

The component, places the given type on the nearest location along the host element. In the image below, the green sphere is the actual location that is passed to the component. Notice that the door is placed on the closest point on the wall.