All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:
Hi,
I have a RadEditor that is created at runtime. Its forecolor and background fill doesn't response. How to get it work? Do I have to reference RadEditor to RadEditorContenArea.CSS? Thanks, D.
protected
void
Page_Load(
object
sender, EventArgs e)
{
RadEditor editor =
new
RadEditor();
editor.ID =
"RadEditor1"
;
editor.OnClientLoad =
"load"
this
.form1.Controls.Add(editor);
}
<script type=
"text/javascript"
>
function
load(sender, args) {
sender.get_contentArea().style.backgroundColor =
"Black"
sender.get_contentArea().style.color =
"Red"
</script>
Shinu,
Your codes work great for setting default fore color and background color. Sorry that my question wasn't clear. My question is how to get the font color and fill color buttons response when an user wants to highlight a text and change the color of it. Thank you, d-cpt // add RadEditor
RadEditor tbComment = new RadEditor();
tbComment.ID = "tbComment" + dr["STECAT_ID"].ToString();
tbComment.CssFiles.Add("~/css/EditorContentArea.css");
//tbComment.OnClientLoad = "load"; // this call the functionload() function which is in MasterSimple.master
tbComment.Width = Unit.Percentage(95);
trcell.Controls.Add(tbComment);
trow.Cells.Add(trcell);
tableEvaluation.Rows.Add(trow);