Hi,
I'm trying to attach a client-side focus event to the RadEditor, which I'm using in Preview mode.
I've tried to follow some of the examples hat I've seen on the forum here. I've got it working correctly in IE, however I'm having trouble in Firefox or Chrome - the focus event doesn't seem to get triggered.
The JavaScript I'm using to set up the focus event is:
And my RadEditor is set up using:
Thanks in advance for any help!
Richard
I'm trying to attach a client-side focus event to the RadEditor, which I'm using in Preview mode.
I've tried to follow some of the examples hat I've seen on the forum here. I've got it working correctly in IE, however I'm having trouble in Firefox or Chrome - the focus event doesn't seem to get triggered.
The JavaScript I'm using to set up the focus event is:
<
script
type
=
"text/javascript"
>
function setupEditorFocus(editor, eventArgs) {
var EditorElement = editor.get_contentArea();
$telerik.addExternalHandler(EditorElement, "focus", function () {
editorFocus(editor.get_id());
});
}
function editorFocus(editorId) {
document.getElementById("messageArea").innerHTML = "Set focus " + Date();
}
</
script
>
And my RadEditor is set up using:
<
telerik:RadEditor
id
=
"RadEditor1"
runat
=
"server"
onclientload
=
"setupEditorFocus"
editmodes
=
"Preview"
>
<
Content
>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</
Content
>
</
telerik:RadEditor
>
Thanks in advance for any help!
Richard