This is a migrated thread and some comments may be shown as answers.

Set cursor location in Editor

3 Answers 86 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Dennis
Top achievements
Rank 1
Dennis asked on 25 Jun 2015, 06:48 PM

I'm trying to set the location of the cursor to the end of the text in my editor.

 Please let me know how I can achieve this goal.

 

Dennis

3 Answers, 1 is accepted

Sort by
0
Alex Gyoshev
Telerik team
answered on 29 Jun 2015, 07:32 AM

Hello Dennis,

See the help topic on how to use ranges to set the location of the cursor. For focusing the last node in the editor, use the last element in the editable content.

Regards,
Alex Gyoshev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Dennis
Top achievements
Rank 1
answered on 30 Jun 2015, 05:44 AM
What do you mean by the last element in the editable content?
0
Alex Gyoshev
Telerik team
answered on 01 Jul 2015, 11:13 AM

Hello Dennis,

This would be editor.body.lastChild, or the end of its previousSibling.

Regards,
Alex Gyoshev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Editor
Asked by
Dennis
Top achievements
Rank 1
Answers by
Alex Gyoshev
Telerik team
Dennis
Top achievements
Rank 1
Share this question
or