Tuesday, June 4, 2013

Html.ActionLink with Area in ASP.NET MVC

When you have added an area into your MVC project, you might need to use Html.ActionLink to navigate to a view inside the newly added area. In that case you can use below code.

@Html.ActionLink("Go To Area","Index","NewCompany",new { area = "Company"},null) 

Go To Area - Link Text
Index - Action Name
NewCompany - Controller
Company - Area

No comments:
Write comments
Recommended Posts × +