Share via


Controller.PartialView Method

Definition

Overloads

PartialView(String, Object)

Creates a PartialViewResult object by specifying a viewName and the model to be rendered by the partial view.

PartialView(String)

Creates a PartialViewResult object by specifying a viewName.

PartialView()

Creates a PartialViewResult object that renders a partial view to the response.

PartialView(Object)

Creates a PartialViewResult object by specifying a model to be rendered by the partial view.

PartialView(String, Object)

Source:
Controller.cs
Source:
Controller.cs
Source:
Controller.cs

Creates a PartialViewResult object by specifying a viewName and the model to be rendered by the partial view.

public:
 virtual Microsoft::AspNetCore::Mvc::PartialViewResult ^ PartialView(System::String ^ viewName, System::Object ^ model);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PartialViewResult PartialView (string viewName, object model);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PartialViewResult PartialView (string? viewName, object? model);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PartialView : string * obj -> Microsoft.AspNetCore.Mvc.PartialViewResult
override this.PartialView : string * obj -> Microsoft.AspNetCore.Mvc.PartialViewResult
Public Overridable Function PartialView (viewName As String, model As Object) As PartialViewResult

Parameters

viewName
String

The name or path of the partial view that is rendered to the response.

model
Object

The model that is rendered by the partial view.

Returns

The created PartialViewResult object for the response.

Attributes

Applies to

PartialView(String)

Source:
Controller.cs
Source:
Controller.cs
Source:
Controller.cs

Creates a PartialViewResult object by specifying a viewName.

public:
 virtual Microsoft::AspNetCore::Mvc::PartialViewResult ^ PartialView(System::String ^ viewName);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PartialViewResult PartialView (string viewName);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PartialViewResult PartialView (string? viewName);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PartialView : string -> Microsoft.AspNetCore.Mvc.PartialViewResult
override this.PartialView : string -> Microsoft.AspNetCore.Mvc.PartialViewResult
Public Overridable Function PartialView (viewName As String) As PartialViewResult

Parameters

viewName
String

The name or path of the partial view that is rendered to the response.

Returns

The created PartialViewResult object for the response.

Attributes

Applies to

PartialView()

Source:
Controller.cs
Source:
Controller.cs
Source:
Controller.cs

Creates a PartialViewResult object that renders a partial view to the response.

public:
 virtual Microsoft::AspNetCore::Mvc::PartialViewResult ^ PartialView();
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PartialViewResult PartialView ();
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PartialView : unit -> Microsoft.AspNetCore.Mvc.PartialViewResult
override this.PartialView : unit -> Microsoft.AspNetCore.Mvc.PartialViewResult
Public Overridable Function PartialView () As PartialViewResult

Returns

The created PartialViewResult object for the response.

Attributes

Applies to

PartialView(Object)

Source:
Controller.cs
Source:
Controller.cs
Source:
Controller.cs

Creates a PartialViewResult object by specifying a model to be rendered by the partial view.

public:
 virtual Microsoft::AspNetCore::Mvc::PartialViewResult ^ PartialView(System::Object ^ model);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PartialViewResult PartialView (object model);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PartialViewResult PartialView (object? model);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PartialView : obj -> Microsoft.AspNetCore.Mvc.PartialViewResult
override this.PartialView : obj -> Microsoft.AspNetCore.Mvc.PartialViewResult
Public Overridable Function PartialView (model As Object) As PartialViewResult

Parameters

model
Object

The model that is rendered by the partial view.

Returns

The created PartialViewResult object for the response.

Attributes

Applies to