Skip to content

Document

Public Class

The Document Creation object is used to create new instances of elements within the Autodesk Revit project.

Inheritance Hierarchy

System.Object
Autodesk.Revit.DB.APIObject
Autodesk.Revit.Creation.ItemFactoryBase
Autodesk.Revit.Creation.Document

Namespace: Autodesk.Revit.Creation

Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)

Syntax

public class Document : ItemFactoryBase

The Document type exposes the following members.

Properties

Name

Description


Public Property
Code Example

Identifies if the object is read-only or modifiable.
(Inherited from APIObject)


Methods

Name

Description


Public Method
Dispose

Causes the object to release immediately any resources it may be utilizing.
(Inherited from APIObject)


Public Method

Equals

Determines whether the specified object is equal to the current object.
(Inherited from Object)


Public Method

GetHashCode

Serves as the default hash function.
(Inherited from Object)


Public Method

GetType

Gets the Type of the current instance.
(Inherited from Object)


Public Method
NewAlignment

Add a new locked alignment into the Autodesk Revit document.
(Inherited from ItemFactoryBase)


Public Method

Creates a new area


Public Method
Code Example
NewAreaBoundaryConditions(Element, TranslationRotationValue, Double, TranslationRotationValue, Double, TranslationRotationValue, Double)

Creates a new Area BoundaryConditions element on a host element.


Public Method
Code Example
NewAreaBoundaryConditions(Reference, TranslationRotationValue, Double, TranslationRotationValue, Double, TranslationRotationValue, Double)

Creates a new Area BoundaryConditions element on a reference.


Public Method

Creates a new boundary line as an Area border.


Public Method

Creates new areas


Public Method

Creates a new area tag.


Public Method

Add a new family instance of a cross fitting into the Autodesk Revit document, using four connectors.


Public Method
NewCurtainSystem

Creates a new CurtainSystem element from a set of faces.


Public Method
NewCurtainSystem2

Creates a new CurtainSystem element from a set of face references.


Public Method
NewDetailCurve

Creates a new detail curve element.
(Inherited from ItemFactoryBase)


Public Method

Creates an array of new detail curve elements.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewDimension(View, Line, ReferenceArray)

Creates a new linear dimension object using the default dimension style.
(Inherited from ItemFactoryBase)


Public Method

Creates a new linear dimension object using the specified dimension style.
(Inherited from ItemFactoryBase)


Public Method

Add a new family instance of an elbow fitting into the Autodesk Revit document, using two connectors.


Public Method
NewExtrusionRoof

Creates a new Extrusion Roof.


Public Method
Code Example
NewFamilyInstance(Face, Line, FamilySymbol)

Inserts a new instance of a family onto a face of an existing element, using a line on that face for its position, and a type/symbol.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewFamilyInstance(Line, FamilySymbol, View)

Add a line based detail family instance into the Autodesk Revit document, using an line and a view where the instance should be placed.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewFamilyInstance(Reference, Line, FamilySymbol)

Inserts a new instance of a family onto a face referenced by the input Reference instance, using a line on that face for its position, and a type/symbol.
(Inherited from ItemFactoryBase)


Public Method
NewFamilyInstance(XYZ, FamilySymbol, StructuralType)

Inserts a new instance of a family into the document, using a location and a type/symbol.
(Inherited from ItemFactoryBase)


Public Method
NewFamilyInstance(XYZ, FamilySymbol, View)

Add a new family instance into the Autodesk Revit document, using an origin and a view where the instance should be placed.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewFamilyInstance(Curve, FamilySymbol, Level, StructuralType)

Inserts a new instance of a family into the document, using a curve, type/symbol and reference level.


Public Method
Code Example
NewFamilyInstance(Face, XYZ, XYZ, FamilySymbol)

Inserts a new instance of a family onto a face of an existing element, using a location, reference direction, and a type/symbol.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewFamilyInstance(Reference, XYZ, XYZ, FamilySymbol)

Inserts a new instance of a family onto a face referenced by the input Reference instance, using a location, reference direction, and a type/symbol.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewFamilyInstance(XYZ, FamilySymbol, Element, StructuralType)

Inserts a new instance of a family into the document, using a location, type/symbol, and the host element.
(Inherited from ItemFactoryBase)


Public Method
NewFamilyInstance(XYZ, FamilySymbol, Level, StructuralType)

Inserts a new instance of a family into the document, using a location, type/symbol, and the level.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewFamilyInstance(XYZ, FamilySymbol, Element, Level, StructuralType)

Inserts a new instance of a family into the document, using a location, type/symbol, the host element and a base level.


Public Method
Code Example
NewFamilyInstance(XYZ, FamilySymbol, XYZ, Element, StructuralType)

Inserts a new instance of a family into the document, using a location, type/symbol, the host element and a reference direction.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewFamilyInstances2

Creates Family instances within the document.
(Inherited from ItemFactoryBase)


Public Method

Creates a fascia along a reference.


Public Method

Creates a fascia along a reference array.


Public Method

Adds a new flexible duct into the document, using a point array and duct type.


Public Method
NewFlexDuct(Connector, Connector, FlexDuctType)

Adds a new flexible duct into the document, using two connector, and duct type.


Public Method
NewFlexDuct(Connector, IList.XYZ., FlexDuctType)

Adds a new flexible duct into the document, using a connector, point array and duct type.


Public Method

Adds a new flexible pipe into the document, using a point array and pipe type.


Public Method
NewFlexPipe(Connector, Connector, FlexPipeType)

Adds a new flexible pipe into the document, using two connector, and flexible pipe type.


Public Method
NewFlexPipe(Connector, IList.XYZ., FlexPipeType)

Adds a new flexible pipe into the document, using a connector, point array and pipe type.


Public Method
Code Example
NewFootPrintRoof

Creates a new FootPrintRoof element.


Public Method
Code Example
NewGroup

Creates a new type of group.
(Inherited from ItemFactoryBase)


Public Method

Creates a gutter along a reference.


Public Method

Creates a gutter along a reference array.


Public Method
Code Example
NewLineBoundaryConditions(Element, TranslationRotationValue, Double, TranslationRotationValue, Double, TranslationRotationValue, Double, TranslationRotationValue, Double)

Creates a new Line BoundaryConditions element on a host element.


Public Method
Code Example
NewLineBoundaryConditions(Reference, TranslationRotationValue, Double, TranslationRotationValue, Double, TranslationRotationValue, Double, TranslationRotationValue, Double)

Creates a new Line BoundaryConditions element on a reference.


Public Method
Code Example
NewMechanicalSystem

Creates a new MEP mechanical system element.


Public Method
Code Example
NewModelCurve

Creates a new model line element.
(Inherited from ItemFactoryBase)


Public Method

Creates an array of new model line elements.
(Inherited from ItemFactoryBase)


Public Method
NewOpening(Element, CurveArray, eRefFace)

Creates a new opening in a beam, brace and column.


Public Method

Creates a new opening in a roof, floor and ceiling.


Public Method
NewOpening(Level, Level, CurveArray)

Creates a new shaft opening between a set of levels.


Public Method
NewOpening(Wall, XYZ, XYZ)

Creates a rectangular opening on a wall.


Public Method
NewPipingSystem

Creates a new MEP piping system element.


Public Method
Code Example
NewPointBoundaryConditions

Creates a new Point BoundaryConditions Element.


Public Method
Code Example
NewReferencePlane

Creates a new instance of ReferencePlane.
(Inherited from ItemFactoryBase)


Public Method
Code Example
NewReferencePlane2

Creates a new instance of ReferencePlane.
(Inherited from ItemFactoryBase)


Public Method

Creates a new unplaced room and with an assigned phase.


Public Method
Code Example
NewRoom(Level, UV)

Creates a new room on a level at a specified point.


Public Method
Code Example
NewRoom(Room, PlanCircuit)

Creates a new room within the confines of a plan circuit, or places an unplaced room within the confines of the plan circuit.


Public Method

Creates a new boundary line as an Room border.


Public Method

Creates new rooms in each plan circuit found in the given level in the last phase.


Public Method

Creates new rooms in each plan circuit found in the given level in the given phase.


Public Method

Creates new unplaced rooms in the given phase.


Public Method
Code Example

Creates a new RoomTag referencing a room in the host model or in a Revit link.


Public Method

Creates a slab edge along a reference.


Public Method

Creates a slab edge along a reference array.


Public Method

Creates a new unplaced space on a given phase.


Public Method

Creates a new space element on the given level at the given location.


Public Method

Creates a new space element on the given level, at the given location, and assigned to the given phase.


Public Method

Creates a new boundary line as an Space border.


Public Method

Creates a set of new unplaced spaces on a given phase.


Public Method
NewSpaces2(Level, Phase, View)

Creates new spaces on the available plan circuits of a the given level.


Public Method

Creates a new SpaceTag.


Public Method
NewSpotCoordinate

Generate a new spot coordinate object within the project.


Public Method
NewSpotElevation

Generate a new spot elevation object within the project.


Public Method

Add a new family instance of an takeoff fitting into the Autodesk Revit document, using one connector and one MEP curve.


Public Method

Add a new family instance of a tee fitting into the Autodesk Revit document, using three connectors.


Public Method

Add a new family instance of an transition fitting into the Autodesk Revit document, using two connectors.


Public Method

Add a new family instance of an union fitting into the Autodesk Revit document, using two connectors.


Public Method

Creates a new Zone element.


Public Method
PlaceGroup

Place an instance of a Model Group into the Autodesk Revit document, using a location and a group type.
(Inherited from ItemFactoryBase)


Public Method

ToString

Returns a string that represents the current object.
(Inherited from Object)


Remarks

The Document Creation object is a utility object that is used to create new instances of elements within the Autodesk Revit project. This object, available from the Document.Create property should be used to create elements instead of using New. This object ensures that the elements created are added to the document correctly.