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.

Regarding TreeView Node Delete

Thread ID:

Created:

Updated:

Platform:

Replies:

75886 Aug 13,2008 09:03 AM Aug 15,2008 06:12 AM ASP.NET Web Forms (Classic) 1
loading
Tags: Tools
Administrator [Syncfusion]
Asked On August 13, 2008 09:03 AM

Hi
I write code for Button Click event remove Selected Treeview node. But it was not working.

Code:
tvQuestionnaire.Items.Remove(tvQuestionnaire.SelectedNode)

1. How to remove or delete selected treeview Node?.
2. Is there any way to delete selected node using js?.

Thank you
Dinesh


Rekha P [Syncfusion]
Replied On August 15, 2008 06:12 AM

Hi Dinesh,

Thank you for your interest in Syncfusion Products.

Regarding,
1. How to remove or delete selected treeview Node?.

Please use the below code in the button click event.
protected void Button1_Click(object sender, EventArgs e)
{
if (TreeView1.SelectedNode != null)
TreeView1.SelectedNode.ParentItem.Items.Remove(TreeView1.SelectedNode);
}

2. Is there any way to delete selected node using js?.

I regret to let you know that currently we do not provide support for deleting the selected node through client side in our code library. We have notified our development team on this regard and will get back to you once we hear back from them.

Please let me know if you have any concerns.

Thanks,
Rekha


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.

;