Hopefully a really simple MVC problem (), I have a controller in my Controllers folder called HomeController which contains a method called Index which looks like this:
public ActionResult Index()
{
return View();
}
My Index view does indeed exist, and on my shared Layout view I have the following link (to my index page)
@Html.ActionLink("Home", "Index")
Am I doing this right? I have a method called Index in my controller which returns my Index view, so shouldn’t this ActionLink work?
ActionLink takes the action name and then the controller name.
See http://msdn.microsoft.com/en-us/library/dd505070(v=vs.108).aspx