TextEditor Class
The TextEditor class defines the text editor for the user.
System.Web.UI.Control
Microsoft.SharePoint.Portal.WebControls.TextEditor
Public Constructors
The following table shows the constructors of the TextEditor class and a brief description of each.
Name | Description |
---|---|
TextEditor | Initializes a new instance of the TextEditor class. |
Public Fields
The following table shows the fields of the TextEditor class and a brief description of each.
Name | Description |
---|---|
MaxTextSizeDefault | Maximum number of characters that the text editor allows. The value is 50,000 HTML characters. |
TableWidth | The width of the table that contains the text editor window. |
m_fIsValid | Specifies whether the size of the text is less than or equal to MaxTextSizeDefault. |
Public Methods
The following table shows the public methods of the TextEditor class and a brief description of each.
Name | Description |
---|---|
MakeTextSafe(String) | Cleans text according to specifications, such as, removing all script and certain URLs. |
Validate | Ensures that the size of the text does not exceed the maximum size limit of 50,000 HTML characters. The Validate method removes all script from the text before validating the size. The Validate method sets the IsValid property. |
Protected Methods
The following table shows the protected methods of the TextEditor class and a brief description of each.
Name | Description |
---|---|
OnLoad(System.EventArgs) | Inherits from System.Web.UI.Controls. |
Render(System.Web.UI.HtmlTextWriter) | Inherits from System.Web.UI.Controls. |
Public Properties
The following table shows the properties of the TextEditor class, the data type of each property, and a brief description of each.
Name | Data type | Description |
---|---|---|
EditableText | String | Gets or sets the raw HTML to display in the Web browser for the user to edit. |
EditorHeight | System.Web.UI.WebControls.Unit | Gets or sets the height of the text editor. The default is 300 pixels. |
EditorWidth | System.Web.UI.WebControls.Unit | Gets or sets the width of the text editor. The default is 600 pixels. |
ErrorMessage | String | Gets or sets the error message that appears above the text editor window. |
ErrorMessageLocId | Microsoft.SharePoint.Portal.WebControls.LocStringId | Reserved for internal use only. |
ErrorMessageLocIdNum | Int32 | Reserved for internal use only. |
IsValid | Boolean | Gets or sets a value indicating whether the size of the text is less than or equal to MaxTextSizeDefault. The Validate method sets the IsValid property. |
RestrictedMode | Boolean | Gets or sets a value indicating whether the text editor is in restricted mode. Restricted mode does not support the Copy, Cut, Paste, or Insert Image function. |
Thread Safety
Any public static (Shared in Microsoft Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread safe.
Requirements
Namespace: Microsoft.SharePoint.Portal.WebControls
Platforms: Microsoft Windows Server 2003
Assembly: Microsoft.SharePoint.Portal (in Microsoft.SharePoint.Portal.dll)
Security: Code Access Security