How to use the menu with events

I really like the menu control and would like to use it for a reason that doesn't use the path, but does call a method when clicked, similar to how "button @click=..." does.

Is there a way to call a method from inside of a MenuItem from where I can call an event, or some other way to call an event?

thanks

Hi @Daniel,

UPDATE: Using the click attribute no longer works because the Menu component now has a dedicated Click event.

The menu item supports custom attributes. This allows you to set a click handler

 <RadzenMenuItem Text="Text" @onclick="@(args => Console.WriteLine(args))">
</RadzenMenuItem>

UPDATE: Using the click attribute no longer works because the Menu component now has a dedicated Click event.

Thanks,
I gave up too soon. It appears it does allow a click hanlder, but only on the first menuitems menuitem.
The menuitems have to highlight from mouse-over, and only the first one in each column will highlight.
I have tried reversing the order and it still holds true, the one that would not highlight before now highlights, and vice verse.
Edit: On a hunch I put back the style="height:120px" and this fixed it.
thank you, and your product is great! I am sure I will be a paying subscriber after this virus thing is over.

This example doesn't work.
Click on RadzenMenuItem doesn't fire onclick event.

Do you have to determine the selected menu item by the text property?

i have same issue what i am missing has any one solved it ?

You can check the update of this post:

thats what exactly i did but its not working

Your code still shows plain HTML @onclick not RadzenMenu Click.

You are the boss! thank you .. here is how i did it.

and then

Could we Have a Click event for the RadzenMenuItem?