RadEditor for ASP.NET

GetContentArea Send comments on this topic.
Client-side API Reference > Methods > GetContentArea

Glossary Item Box


Returns a reference to the editor's content area.

JavaScript Copy Code
function GetContentArea()

You can use this method for example to customize the appearance of the editor's content area. The following example demonstrates how to apply different style properties to the content area and change its look:

 

ASPX/ASCX Copy Code
<script type="text/javascript">
function OnClientLoad(editor)
{
   
var style = editor.GetContentArea().style;
   style.backgroundColor
= "black";
   style.color
= "red";
   style.fontFamily
= "Arial";
   style.fontSize
= "15";
}
</script>
<
rad:RadEditor id="RadEditor1" Runat="server" OnClientLoad="OnClientLoad"></rad:RadEditor>