SetName Method


Transaction Set Name Method

Sets the transaction's name.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.3.0.0 (25.3.0.0)
Syntax
public void SetName(
	string name
)

Parameters

name String
A name for the transaction.
Exceptions
Exception Condition
ArgumentException The name argument is an empty string.
ArgumentNullException A non-optional argument was null
Remarks
A transaction needs a name before it can be started, i.e. before one of the 'Start' method is invoked for this transaction object. The name will later appear in the Undo menu in Revit after a transaction is successfully committed.

Another ways of setting the name is either during construction or during the Start(String) method.

See Also