MvcForm 建構函式
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
MvcForm(HttpResponseBase) |
已淘汰.
使用指定的 HTTP 回應物件, MvcForm 初始化 類別的新實例。 |
MvcForm(ViewContext) |
使用指定的檢視內容, MvcForm 初始化 類別的新實例。 |
MvcForm(HttpResponseBase)
警告
This constructor is obsolete, because its functionality has been moved to MvcForm(ViewContext) now.
使用指定的 HTTP 回應物件, MvcForm 初始化 類別的新實例。
[System.Obsolete("This constructor is obsolete, because its functionality has been moved to MvcForm(ViewContext) now.", true)]
public MvcForm (System.Web.HttpResponseBase httpResponse);
new System.Web.Mvc.Html.MvcForm : System.Web.HttpResponseBase -> System.Web.Mvc.Html.MvcForm
Public Sub New (httpResponse As HttpResponseBase)
參數
- httpResponse
- HttpResponseBase
HTTP 回應物件。
- 屬性
例外狀況
參數 httpResponse
為 null。
適用於
MvcForm(ViewContext)
使用指定的檢視內容, MvcForm 初始化 類別的新實例。
public MvcForm (System.Web.Mvc.ViewContext viewContext);
new System.Web.Mvc.Html.MvcForm : System.Web.Mvc.ViewContext -> System.Web.Mvc.Html.MvcForm
Public Sub New (viewContext As ViewContext)
參數
- viewContext
- ViewContext
封裝呈現檢視所需資訊的物件。
例外狀況
viewContext
參數為 null。