RadTextBox
RadTextBox is a simple input control for letting the user enter text values. It shares the common properties of all RadInput controls, including support for skins, styles for different states, empty message support, conditional postback on text change, flexible caret and button positioning, labels, and so on. You can find information on the Server-side API of RadTextBox at .
Definition
Namespace:Telerik.Web.UI
Assembly:Telerik.Web.UI.dll
Syntax:
[ClientScriptResource("Telerik.Web.UI.RadTextBox", "Telerik.Web.UI.Input.TextBox.RadInputScript.js")]
[ValidationProperty("ValidationText")]
[ControlValueProperty("Text")]
[ToolboxBitmap(typeof(RadTextBox), "Toolbox.Icons.Input.png")]
[TelerikToolboxCategory("Data Editing")]
public class RadTextBox : RadInputControl, IComponent, IDisposable, IParserAccessor, IUrlResolutionService, IDataBindingsAccessor, IControlBuilderAccessor, IControlDesignerAccessor, IExpressionsAccessor, IAttributeAccessor, IScriptControl, IControlResolver, IPostBackDataHandler, ISkinnableControl, IControl, IPostBackEventHandler, INamingContainer, IEditableTextControl, ITextControl
Inheritance: objectControlWebControlRadWebControlRadInputControlRadTextBox...
Implements:
Inherited Members
Constructors
public RadTextBox()
Properties
Gets or sets the display width of the RadTextBox in characters.
public virtual int Columns { get; set; }
The display width, in characters, of the RadTextBox. The default is 0, which indicates that the property is not set.
Exceptions: ArgumentOutOfRangeExceptionThe specified width is less than 0.
.NET Framework
Supported in: 3.0, 2.0, 1.1, 1.0
Get or sets the specific HTML input type that will be rendered in the control
public virtual Html5InputType InputType { get; set; }
Gets the settings that are determining the strenght of a RadTextBox with type set to password.
[PersistenceMode(PersistenceMode.InnerProperty)]
public InputPasswordStrengthSettings PasswordStrengthSettings { get; }
The settings that are determining the strenght of a RadTextBox with type set to password.
Use this property to set resizing mode of RadTextBox when TextMode is InputMode.MultiLine.
public ResizeMode Resize { get; set; }
Supports ResizeMode enumeration values: None, Both, Horizontal, and Vertical
Gets or sets the number of rows displayed in a multiline RadTextBox.
[Themeable(false)]
public virtual int Rows { get; set; }
The number of rows in a multiline RadTextBox. The default is 0, which displays a two-line text box.
Use the Rows property to specify the number of rows displayed in a multiline RadTextBox. This property is applicable only when the TextMode property is set to MultiLine. This property cannot be set by themes or style sheet themes. This example has a text box that accepts user input, which is a potential security threat. By default, ASP.NET Web pages validate that user input does not include script or HTML elements.
Gets or sets a value indicating whether a toggle button for showing/hiding the password is displayed. Only effective when TextMode is set to Password.
public bool ShowPasswordButton { get; set; }
public virtual string SmartPasteDescription { get; set; }
protected override HtmlTextWriterTag TagKey { get; }
Overrides:
Gets or sets the behavior mode (single-line, multiline, or password) of the RadTextBox control.
public InputMode TextMode { get; set; }
One of the RadInputTextBoxMode enumeration values. The default value is SingleLine.
Exceptions: ArgumentOutOfRangeExceptionThe specified mode is not one of the TextBoxMode enumeration values.
Use the TextMode property to specify whether a RadTextBox control is displayed as a single-line, multiline, or password text box.
When the RadTextBox control is in multiline mode, you can control the number of rows displayed by setting the Rows property. You can also specify whether the text should wrap by setting the Wrap property.
If the RadTextBox control is in password mode, all characters entered in the control are masked.
This property cannot be set by themes or style sheet themes
Gets or sets a value indicating whether the text content wraps within a multiline RadTextBox.
public virtual bool Wrap { get; set; }
true if the text content wraps within a multiline RadTextBox; otherwise, false. The default is true.
Use the Wrap property to specify whether the text displayed in a multiline RadTextBox control automatically continues on the next line when the text reaches the end of the control. This property is applicable only when the RadTextMode property is set to MultiLine
Methods
protected override void AddAttributesToRender(HtmlTextWriter writer)
Overrides:
Code moved into this method from OnPreRender to make sure it executed when the framework skips OnPreRender() for some reason
protected override void ControlPreRender()
Overrides:
protected override void CreateChildControls()
Overrides:
protected override void DescribeClientEvents(IScriptDescriptor descriptor)
Overrides:
protected override void DescribeClientProperties(IScriptDescriptor descriptor)
Overrides:
protected override void DescribeComponent(IScriptDescriptor descriptor)
Overrides:
protected override void DescribeValueAndTextProperties(IScriptDescriptor descriptor)
Overrides:
protected override void RenderBeginTagSingleInput(HtmlTextWriter writer)
Overrides:
protected override void RenderChildren(HtmlTextWriter writer)
Overrides:
protected override void RenderContentsSingleInput(HtmlTextWriter writer)
Overrides:
protected override void RenderPasswordStrengthIndicator(HtmlTextWriter writer, bool inTable)
Overrides:
protected override void SetDefaultSize()
Overrides: