DocumentNewSpaces2(Level, Phase, View) Method

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

Namespace: Autodesk.Revit.Creation
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntax
public ICollection<ElementId> NewSpaces2(
	Level level,
	Phase phase,
	View view
)

Parameters

level  Level
The level on which the spaces is to exist.
phase  Phase
The phase in which the spaces is to exist.
view  View
The view on which the space tags for the spaces are to display.

Return Value

ICollectionElementId
If successful, a set of ElementIds which contains the rooms should be returned, otherwise the exception will be thrown.
Exceptions
ExceptionCondition
ArgumentOutOfRangeExceptionThe view of the relevant level can not be retrieved.
InvalidOperationExceptionThe phase is invalid or regeneration fails at the end of the creation.
ArgumentExceptionThrown if the level does not exist in the given document.
ArgumentExceptionThrown if the phase does not exist in the given document.
ArgumentExceptionThrown if the view does not exist in the given document.
Remarks
This method will regenerate the document even in manual regeneration mode.
See Also