FilePathResult(String, String) 构造函数

定义

使用指定的文件名和内容类型初始化 类的新实例 FilePathResult

public FilePathResult (string fileName, string contentType);
new System.Web.Mvc.FilePathResult : string * string -> System.Web.Mvc.FilePathResult
Public Sub New (fileName As String, contentType As String)

参数

fileName
String

要发送到响应的文件的名称。

contentType
String

响应的内容类型。

例外

参数 fileName 为 null 或空。

适用于