Hello.
I just started using Rad Controls, and i have some problems.
I want to put a custom button in RadEditor control, (actually it's a dropdown list). Each of the values of the dropdown list, will lead to a function that changes the tools file(xml) that the radEditor uses.
I already made the dropdown list, and created the function to do this. But the problem is that, after choosing a certain value, the page is set to be reloaded, and it will load the Editor with the default tools file. Is there any way to accomplish this? I was thinking of some way to reload only the RadEditor with the new tools file, but i haven't seen a command to do just that.
for the moment is use this script to change the tools file.
The second problem i seem to have, involves the customization of an already existing button - FullScreen. I want the button to co to full screen, but the textarea of the edited text to remain the same. In other words, when using fullscreen i wish to see the tools in the upper bar, just like fullscreen. But the editing content to remain as the same size as in the original page. If it was 200x200px i want it to remain the same.
The third and final problem i am facing, and have no ideea how to solve is to autohide, via button, certain sets of tools, let's say i don't want to see the font size&alignment, i should be able to show/hide those with one button, something like and collapsible panel. I hope i made myself clear, and to receive any help soon.
I just started using Rad Controls, and i have some problems.
I want to put a custom button in RadEditor control, (actually it's a dropdown list). Each of the values of the dropdown list, will lead to a function that changes the tools file(xml) that the radEditor uses.
I already made the dropdown list, and created the function to do this. But the problem is that, after choosing a certain value, the page is set to be reloaded, and it will load the Editor with the default tools file. Is there any way to accomplish this? I was thinking of some way to reload only the RadEditor with the new tools file, but i haven't seen a command to do just that.
for the moment is use this script to change the tools file.
<script type="text/javascript"> |
Telerik.Web.UI.Editor.CommandList["Custom"] = function (commandName, editor, args) { |
alert("Custom command 1"); |
//for example you can apply bold formatting by firing the editor.fire("Bold"); |
}; |
Telerik.Web.UI.Editor.CommandList["Drop1"] = function (commandName, editor, args) { |
alert("Custom command 2"); |
// Execute your code here, provide it with any arguments that you need, etc. |
}; |
Telerik.Web.UI.Editor.CommandList["ButtonPresets"] = function (commandName, editor, oTool) { |
//alert("Value Selected: " + oTool.get_value()); |
//var editorName = "ContentPlaceHolder2_RadEditor2Wrapper" |
//document.getElementById(ContentPlaceHolder2_RadEditor2Wrapper).ToolFile = "~/RadEditor Tools/ToolsFile" + oTool.get_value() +".xml" |
editor.ToolsFile = "~/RadEditor Tools/ToolsFile" + oTool.get_value() + ".xml" |
//documentdocument.location = document.location; |
}; |
</script> |
The second problem i seem to have, involves the customization of an already existing button - FullScreen. I want the button to co to full screen, but the textarea of the edited text to remain the same. In other words, when using fullscreen i wish to see the tools in the upper bar, just like fullscreen. But the editing content to remain as the same size as in the original page. If it was 200x200px i want it to remain the same.
The third and final problem i am facing, and have no ideea how to solve is to autohide, via button, certain sets of tools, let's say i don't want to see the font size&alignment, i should be able to show/hide those with one button, something like and collapsible panel. I hope i made myself clear, and to receive any help soon.