views:

346

answers:

3

Hi all,

I have a treeview showing Categories and subcategories. I need to Right Click Option to add subcategories and products for a particular category or subcategory.

What I want is suppose I have selected a treenode showing a category or subcategory. When I right click on a treenode it will show a contextmenu having options -- Add subcategory, Add product, Delete this category, Edit this category. When I click on one of the menu item it will open a popup to add/Edit/Delete Category or add product.

I hope you can understand my problem. please help.

Thanks in advance.

A: 

I recommend the jQuery plugin jContext. You might have to do a couple extra things when working with ASP.NET webforms.

You will have to study the html that gets generated by the treeview control.

For example, web forms controls render html elements with an ID attribute that can vary on many factors. So, your javascript code will have to reference these elements in a different way than usual:

$('#<%=someControl.ClientID %>').whatever();
Ronnie Overby
A: 

It's pretty complicated, so if you're not sure what you're doing you'd be better off googling for a 3rd party component that already does right-click.

e.g.

http://aspnetajax.componentart.com/control-specific/treeview/features/node%5FcontextMenus/WebForm1.aspx

wefwfwefwe
Do I have to buy the componentart web UI?
Himadri
If only they had a website or something...
wefwfwefwe
A: 

I have found a solution FlyTreeView for ASP.NET (versions 2.0, 3.0, 3.5) in this Link

Thanks everyone for your time.

Himadri