473,320 Members | 1,865 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Click event for menu's child items

Med
Hi,

How can I fire click event for menus child items? My menu is located in a
WebUserControl as follow:

<asp:Menu ID="mnuMain"
runat="server"
OnMenuItemClick="Menu1_MenuItemClick"
Orientation=Horizontal >

<Items>
<asp:MenuItem Text="Parent1" Value="Parent1" />
<asp:MenuItem Text="Parent2" Value="Parent2">
<asp:MenuItem Text="Parent2Child" Value="Parent2Child" />
</asp:MenuItem>
</Items>

</asp:Menu>

Using following, I can trap click events for Parent1 and Parent2, but I also
need to get Parent2Child click events. How can I do it?

protected void Menu1_MenuItemClick(object sender, MenuEventArgs e)
{
switch (e.Item.Value)
{
case "Parent1":
////....
break;

case "Parent2":
////....
break;
}
}

Thanks for your time.

Regards

Med
Mar 19 '07 #1
0 1229

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Dan H | last post by:
I'm trying to add menu items dynamically in the Popup event of a MenuItem in an MDI child form. Actually, I'm using the Genghis MRU class, but have also dumbed it down to a simple test case in a...
5
by: Al Christoph | last post by:
I have a program that mixes wizard like behavior with random access to the various dialogs in the wizard. I do this by having each step map to a toolstripmenuitem. Users can randomly choose the...
2
by: Pete | last post by:
I have some funky form/event behavior. Access 97. Split frontend/backend, using Access security. I have the same behavior (or lack of behavior) for the pag_Click() event of two separate pages...
1
by: Sakharam Phapale | last post by:
Hi All, How to show dropdown list of menu items just like click on Parent menu. For example, Edit (Parent menu) Cut (child menu) Copy (child menu) Paste (child menu)
2
by: Sakharam Phapale | last post by:
Hi All, How to show dropdown list of menu items just like click on Parent menu. For example, Edit (Parent menu) Cut (child menu) Copy (child menu) Paste (child menu)
11
by: Terry Olsen | last post by:
How can I catch a right-click on a DropDownMenuItem?
2
by: Hardik Shah | last post by:
Hi, I want to create menu , when my user right click from combo box's list item. I use Contextmenu property of combobox and assign menu for it, but it only effected when combobox's list item not...
0
by: jojobar | last post by:
We are using the ASP:Menu control (horizontal) for site navigation. We would prefer that the menu items only be expanded when we click on a top level menu item rather than when the cursor hovers...
1
by: Anthony | last post by:
Below is a script I found at http://javascript.internet.com/ for a cascading menu. The script works great but there is one thing that I would like modified. BecauseI am just learning javascript,...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.