The directory structure is:
controllers -> HomeController, TableController
views -> home -> index.cshtml
views -> Table -> Navigate.cshtml
The index.cshtml corresponds to the index method in the HomeController
the navigate.cshtml is a partial view and corresponds to the Navigate method in the TableController. The navigate method's return type is PartialViewResult
and returns:
PartialView("Navigate", Data);
The Index.cshtml has @Html.RenderPartial()
...
if I wanted to call the partial view from the TableController, could I just say:
@Html.RenderPartial("~/Controllers/Table/Navigate");
So it renders the partial view returned by navigate method in the TableController.
IF all you want to do is to include the partial view. Why not call it using action method. Like:
@Html.Action("Navigate","Table")
You can place this anywhere and it should work.