Article information Article relates to RadEditor 5.x - 7.x, RadEditor "Prometheus" Created by Rumen Zhekov Last modified 2008/03/14 Last modified by Georgi Popivanov HOW-TO Add RadEditor programmatically to a page. SOLUTION You can place a placeholder in your ASPX/ASCX template, e.g. ... <asp:PlaceHolder runat="server" id="editorPlace" /> ...
Article information
Article relates to
RadEditor 5.x - 7.x, RadEditor "Prometheus"
Created by
Rumen Zhekov
Last modified
2008/03/14
Last modified by
Georgi Popivanov
and then, in Page_Load, instantiate a new Editor and add it to the controls collection of the placeholder. All properties of the edit can be set in Page_Load, e.g. C# private void Page_Load(object sender, System.EventArgs e) { RadEditor editor = new RadEditor(); editor.ID = "RadEditor1"; editor.ToolsFile = "~/RadControls/Editor/ToolsFile.xml"; editor.Editable = true; editorPlace.Controls.Add(editor); } VB.NET Private Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Dim editor As RadEditor = New RadEditor editor.ID = "RadEditor1" editor.ToolsFile = "~/RadControls/Editor/ToolsFile.xml" editor.Editable = True editorPlace.Controls.Add(editor) End Sub C# private void Page_Load(object sender, System.EventArgs e) { RadEditor editor = new RadEditor(); editor.ID = "RadEditor1"; //editor.ToolsFile = "~/<folder>/ToolsFile.xml"; editor.Enabled = true; editorPlace.Controls.Add(editor); } VB.NET Private Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Dim editor As RadEditor = New RadEditor editor.ID = "RadEditor1" //editor.ToolsFile = "~/<folder>/ToolsFile.xml" editor.Enabled = True editorPlace.Controls.Add(editor) End Sub
VB.NET Private Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Dim editor As RadEditor = New RadEditor editor.ID = "RadEditor1" //editor.ToolsFile = "~/<folder>/ToolsFile.xml" editor.Enabled = True editorPlace.Controls.Add(editor) End Sub
Resources Buy Try