We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Adding nodes using Key Board

Thread ID:

Created:

Updated:

Platform:

Replies:

42858 Apr 7,2006 03:48 AM Apr 7,2006 08:43 AM Windows Forms 1
loading
Tags: Tools
Administrator [Syncfusion]
Asked On April 7, 2006 03:48 AM

Hi forum, Is it possible to add nodes in the treeViewAdv when a key is pressed and key down in which the text of the node should reflect the key that is used for adding the node. Thanks, Todd

Deepa TS [Syncfusion]
Replied On April 7, 2006 08:43 AM

Hi Todd, You could add nodes to the TreeViewAdv and get the key reflected to the text of the node that is being used for adding the nodes by handling the TreeViewAdv keyDown event handler. private void treeViewAdv1_KeyDown(object sender, System.Windows.Forms.KeyEventArgs e) { TreeNodeAdv node=new TreeNodeAdv("Node"+" "+e.KeyData.ToString()); this.treeViewAdv1.SelectedNode.Nodes.Add(node); Console.WriteLine("The "+node.Text+" "+"is added"); } Please take a look at the attached sample and let me know if this helps you. Thanks for your interest in Syncfusion products. Regards, Deepa.

AddNodesThroKey.zip

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;