Z 10 ) PARTIAL VIEWS IN ASP.NET MVC
PARTIAL VIEWS IN ASP.NET MVC · Partial view represents a sub-view of a main view. · Partial view allows you to reuse common markups across the different views of the application. · We can use partial views in different views. · Partial views cannot be used separately, we have to attach partial in some other view. · Partial view extension is .cshtml like a view. · When we have to use some html markup on some pages not all pages then we can use partial view. To create a partial view in Visual Studio .NET, you need to perform the following steps: 1. Right-click the Views/Shared folder in the Solution Explorer window and select Add View. The AddView dialog box is displayed. 2. In the AddView dialog box, specify a name for the partial view in the View Name text field. 3. Select the Create as a partial view check box. There are 2 types of partial views. 1. Static a. Views whose layout not changed i.e header,...