Revit 2025.3 API
Numbering |
Removes gaps, if any, in a numbering sequence
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.3.0.0 (25.3.0.0)
Syntax
public void RemoveGaps( string partition )
Public Sub RemoveGaps ( partition As String )
public: void RemoveGaps( String^ partition )
member RemoveGaps : partition : string -> unit
Parameters
- partition String
- Name of the partition that identifies the sequence. The sequence must exist.

Exception | Condition |
---|---|
ArgumentException | The sequence partition does not exist in the schema. |
ArgumentNullException | A non-optional argument was null |
InvalidOperationException | Either the schema or its document cannot be modified at present. |

Gaps are removed by shifting numbers above each gap down by the amount of
numbers skipped in the gap. The lowest number in the sequence will remain unchanged.
See Also