PageModel.PhysicalFile PageModel.PhysicalFile PageModel.PhysicalFile Method

Definition

Overloads

PhysicalFile(String, String) PhysicalFile(String, String) PhysicalFile(String, String)

Returns the file specified by physicalPath (Status200OK) with the specified contentType as the Content-Type.

PhysicalFile(String, String, String) PhysicalFile(String, String, String) PhysicalFile(String, String, String)

Returns the file specified by physicalPath (Status200OK) with the specified contentType as the Content-Type and the specified fileDownloadName as the suggested file name.

PhysicalFile(String, String) PhysicalFile(String, String) PhysicalFile(String, String)

Returns the file specified by physicalPath (Status200OK) with the specified contentType as the Content-Type.

public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType);
abstract member PhysicalFile : string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String) As PhysicalFileResult

Parameters

physicalPath
String String String

The physical path of the file to be returned.

contentType
String String String

The Content-Type of the file.

Returns

PhysicalFile(String, String, String) PhysicalFile(String, String, String) PhysicalFile(String, String, String)

Returns the file specified by physicalPath (Status200OK) with the specified contentType as the Content-Type and the specified fileDownloadName as the suggested file name.

public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string fileDownloadName);
abstract member PhysicalFile : string * string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, fileDownloadName As String) As PhysicalFileResult

Parameters

physicalPath
String String String

The physical path of the file to be returned.

contentType
String String String

The Content-Type of the file.

fileDownloadName
String String String

The suggested file name.

Returns

Applies to