Text |
The TextBox object represents text-based control that allows the user to enter text.

Namespace: Autodesk.Revit.UI
Assembly: RevitAPIUI (in RevitAPIUI.dll) Version: 25.0.0.0 (25.0.0.0)

The TextBox type exposes the following members.

Name | Description | |
---|---|---|
![]() | Enabled | Gets or sets a value indicating whether the item is enabled. (Inherited from RibbonItem ) |
![]() | Image | The image of the TextBox. |
![]() | ItemText | Gets or sets the text displayed on the item. (Inherited from RibbonItem ) |
![]() | ItemType | Gets the item type. (Inherited from RibbonItem ) |
![]() | LongDescription | Long description of the command tooltip (Inherited from RibbonItem ) |
![]() | Name | The name of the item. (Inherited from RibbonItem ) |
![]() | PromptText | The prompt text for the text box. |
![]() | SelectTextOnFocus | A value that indicates if the text is selected when the text box gains focus. |
![]() | ShowImageAsButton | Gets or sets a value that indicates if the Image set in the text box should be displayed as a clickable button. |
![]() | ToolTip | The description that appears as a ToolTip for the item. (Inherited from RibbonItem ) |
![]() | ToolTipImage | The image to show as a part of the button extended tooltip (Inherited from RibbonItem ) |
![]() | Value | The object that supplies the text value. |
![]() | Visible | Gets or sets a value indicating whether the item is visible. (Inherited from RibbonItem ) |
![]() | Width | Gets or sets the width of the TextBox. |

Name | Description | |
---|---|---|
![]() | Equals | Determines whether the specified Object is equal to the current Object . (Inherited from RibbonItem ) |
![]() | GetContextualHelp | Gets the contextual help bound with this control. (Inherited from RibbonItem ) |
![]() | GetHashCode | Serves as the default hash function. (Inherited from Object ) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object ) |
![]() | SetContextualHelp | Sets the contextual help bound with this button. (Inherited from RibbonItem ) |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object ) |

Name | Description | |
---|---|---|
![]() | EnterPressed | Subscribe to this event to be notified when the Enter button is pressed in the text box. |

The ItemText property inherited from RibbonItem has no effect. The text entered in the TextBox is edited by the UI user is accepted only if the user presses the Enter key or click the image button when ShowImageAsButton is true. If the user clicks off of this component without pressing Enter or click the image button; then the text will be reverted to the previous value. Use of this class is not supported in Revit Macros.
