how to get tools file on client side

3 posts, 0 answers
  1. srinivas
    srinivas avatar
    27 posts
    Member since:
    Aug 2008

    Posted 25 Aug 2008 Link to this post

    Hi,

    I have 2 toolsfiles and i have 2 buttons. Based on button click i want to load toolsfile to radeditor. How can i achieve this on clientside.
  2. Rumen
    Admin
    Rumen avatar
    14431 posts

    Posted 25 Aug 2008 Link to this post

    Hi Srinivas,

    The editor's toolbars are entirely created on the server and the only possible way to change them on the client is to use an AJAX callback.

    Here is a sample example:

    ASPX:


        <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>

        <asp:UpdatePanel ID="UP1" runat="server">
            <ContentTemplate>
                <telerik:radeditor runat="server" ID="RadEditor1"></telerik:radeditor>
                <asp:Button ID="Button1" runat="server" Text="Set ToolsFile 1" />
                <asp:Button ID="Button2" runat="server" Text="Set ToolsFile 2" />
            </ContentTemplate>
        </asp:UpdatePanel>

    ASPX.VB

        Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
            RadEditor1.ToolsFile = "~/ToolsFile1.xml"
        End Sub

        Protected Sub Button2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button2.Click
            RadEditor1.ToolsFile = "~/ToolsFile2.xml"
        End Sub


    Kind regards,
    Rumen
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. Runat="Server"
    Runat="Server" avatar
    14 posts
    Member since:
    Feb 2010

    Posted 08 Dec 2011 Link to this post

    Hello,

    It's not right!!!!!!!

    I have 16 toolsfiles XML and one editor on my page!

    Why create 10 editors?

    Please find solution for this issue!

    This is a must!

    Thanks. 
Back to Top