All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:
I have prepared a sample code snippet demonstrating how to start the editing process when handling a key:
public RadForm1() { InitializeComponent(); this.radTreeView1.AllowEdit = true; this.radTreeView1.KeyDown += RadTreeView1_KeyDown; } private void RadTreeView1_KeyDown(object sender, KeyEventArgs e) { if (this.radTreeView1.SelectedNode!=null) { this.radTreeView1.BeginEdit(); if (this.radTreeView1.ActiveEditor!=null) { this.radTreeView1.ActiveEditor.Value = e.KeyData.ToString(); TreeViewTextBoxEditor editor = this.radTreeView1.ActiveEditor as TreeViewTextBoxEditor; if (editor!=null) { BaseTextBoxEditorElement el = editor.EditorElement as BaseTextBoxEditorElement; el.TextBoxItem.SelectionStart = el.Text.Length; } } } }
I hope this information helps. If you need any further assistance please don't hesitate to contact me.
Regards, Dess | Tech Support Engineer, Principal Progress Telerik
Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.