MVC 4 Getting the current Area, Controller and Action

Viewed 15011

In my Layout.cshtml I call RenderAction to show the menu for every page request:

 Html.RenderAction("NiceMenu", "Widgets", new {area = ""});

The WidgetController needs to know the parent executing Controller and Action calling it so that it can render the menu with the right item highlighted.

How can the Widget Controller's NiceMenu action know this?

2 Answers
Related