ASP.NET MVC partial view

To create the reusable components we will use the Partial Views. There are two types of Partial Views:
Static partial view: It will return static data
@html.RenderPartial(“Partial view”); Will return void displays ouput on viewpage.
@html.Partial(“partialview”): Return MVC HTML string , you can store it in particular variable.
Dynamic partial view: To implement dynamic data
@html.Action(“partialview”):Will return MVC html string

Let us see partial view example step by step:-
Step 1:
Create new project called "AspnetMVCPartialViewDemo"

Step 2:
Now we are going to create 2 partial views , one is Navigationbar partial view and another one is FooterPartial view.
Step 3:
Go to Shared folder and create NavBarPartialview.cshtml
Step 4:
Create another partial view called "FooterView.cshtml"
Step 5:
Eventually modify _Layout.cshtml to invoke both Navigationbar and Footer partial views.

<div class="navbar navbar-inverse navbar-fixed-top">
var disppartialview = Html.Partial("_NavBarPartialView");         
    <div class="container body-content">
    <hr >
@{Html.RenderPartial("_FooterView"); }

Step 6:
Run AspnetMVCPartialViewDemo application to view the output