Linking to actions in the default area in MVC 4
If you are using multiple areas in your MVC application, when you link to an action in a controller in your default area you will be stuck inside the area you are in now.
Use this:
@Html.ActionLink("Home", "Index", "Home", new { Area = ""}, null)
This will force the area to be the default one.
Written by Andrew Binstead
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#.net
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#