WebResourceAttribute(String, String) 建構函式

定義

使用指定的 Web 資源和資源內容類型,初始化 WebResourceAttribute 類別的新執行個體。

public:
 WebResourceAttribute(System::String ^ webResource, System::String ^ contentType);
public WebResourceAttribute (string webResource, string contentType);
new System.Web.UI.WebResourceAttribute : string * string -> System.Web.UI.WebResourceAttribute
Public Sub New (webResource As String, contentType As String)

參數

webResource
String

Web 資源的名稱。

contentType
String

資源的類型,例如 "image/gif""text/javascript"

例外狀況

webResourcenull 或空字串 ("")。

-或-

contentTypenull 或空字串 ("")。

適用於