WebExtensionsErrorView(Controller, ValidationResult, String, NullableHttpStatusCode) - метод
Creates ViewResult object to show web client error page.
Return it from controller method to navigate to error page.
Пространство имён: Tessa.WebСборка: Tessa.Web (в Tessa.Web.dll) Версия: 4.0.4
public static ViewResult ErrorView(
this Controller controller,
ValidationResult? result,
string? caption = null,
HttpStatusCode? statusCode = null
)
<ExtensionAttribute>
Public Shared Function ErrorView (
controller As Controller,
result As ValidationResult,
Optional caption As String = Nothing,
Optional statusCode As HttpStatusCode? = Nothing
) As ViewResult
public:
[ExtensionAttribute]
static ViewResult^ ErrorView(
Controller^ controller,
ValidationResult^ result,
String^ caption = nullptr,
Nullable<HttpStatusCode^> statusCode = nullptr
)
[<ExtensionAttribute>]
static member ErrorView :
controller : Controller *
result : ValidationResult *
?caption : string *
?statusCode : Nullable<HttpStatusCode>
(* Defaults:
let _caption = defaultArg caption null
let _statusCode = defaultArg statusCode null
*)
-> ViewResult
- controller Controller
- Controller used to create ViewResult.
- result ValidationResult
- Messages to display in error page, null is for empty result.
- caption String (Optional)
- Dialog caption, or null/empty string if default caption is used.
- statusCode NullableHttpStatusCode (Optional)
- HTTP status code for the result object, or null, if default value is used.
ViewResultCreated object. Return it from controller method to navigate to error page.В Visual Basic и C# этот метод можно вызывать как метод экземпляра для любого объекта типа
Controller. При вызове метода для экземпляра следует опускать первый параметр. Дополнительные сведения см. в разделе
Методы расширения (Visual Basic) или
Методы расширения (Руководство по программированию в C#).
Do not use if not web client is available for current web application.