Force floating toolbar display on load

2 posts, 0 answers
  1. Jeremy Zoerman
    Jeremy Zoerman avatar
    3 posts
    Member since:
    Apr 2010

    Posted 12 Aug 2010 Link to this post

    Hello All,

    I am aware the lazy initialization (when not in default mode) is by design. Can I force initialization/display when the page is loaded when ToolbarMode="Floating"?

    I would like the toolbar to be displayed on page load rather than having to click the toggle button.



  2. Rumen
    Rumen avatar
    12788 posts

    Posted 17 Aug 2010 Link to this post

    Hi Jeremy,

    You can open the Floating toolbar when the editor loads using the following code and reposition it:
    <script type="text/javascript">
        // Rad Editor Extensions Initialization
        function OnNewEditorClientLoad(editor, args) {
        function ToggleFloatingToolbar(editor) {
            var button = getElementsByClassName("ToggleFloatingToolbar")[0];
            setTimeout(function() {
                var oWnd = editor.get_toolAdapter().get_window();
                oWnd.moveTo(0, 100);
            }, 10);
        function getElementsByClassName(classname, node) {
            if (!node) node = document.getElementsByTagName("body")[0];
            var a = [];
            var re = new RegExp('\\b' + classname + '\\b');
            var els = node.getElementsByTagName("*");
            for (var i = 0, j = els.length; i < j; i++)
                if (re.test(els[i].className)) a.push(els[i]);
            return a;
        //simulate InternetExplorer's click() method
        if (!document.all) {
   = function() {
                var evt = this.ownerDocument.createEvent('MouseEvents');
                evt.initMouseEvent('click', true, true, this.ownerDocument.defaultView, 1, 0, 0, 0, 0, false, false, false, false, 0, null);
    <telerik:RadEditor runat="server" id="RadEditor1" toolbarmode="Floating" onclientload="OnNewEditorClientLoad"></telerik:RadEditor>

    Best regards,
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Telerik UI for ASP.NET Core is out
Back to Top