15.2 Constructor Reference
The HttpException provides several overloaded constructors for
communicating custom HTTP error information:
- Dim MyHttpEx As New HttpException( )
-
Creates an empty instance of HttpException.
- Throw New HttpException(string)
-
Throws an HttpException whose Message property is set to the value of
the string passed into the constructor.
- Throw New HttpException(integer, string)
-
Throws an HttpException whose GetHttpCode method will return the
integer value passed into the constructor, and whose Message property
is set to the value of the string passed into the constructor.
- Throw New HttpException(string, Exception)
-
Throws an HttpException whose Message property is set to the value of
the string passed into the constructor, and whose InnerException
property is set to the Exception object passed into the constructor.
- Throw New HttpException(string, integer)
-
Throws an HttpException whose Message property is set to the value of
the string passed into the constructor, and whose ErrorCode property
is set to the value of the integer passed into the constructor.
- Throw New HttpException(integer, string, Exception)
-
Throws an HttpException whose GetHttpCode method returns the integer
value passed into the constructor, whose Message property is set to
the value of the string passed into the constructor, and whose
InnerException property is set to the Exception object passed into
the constructor.
- Throw New HttpException(integer, string, integer)
-
Throws an HttpException whose GetHttpCode method returns the first
integer value passed into the constructor, whose Message property is
set to the value of the string passed into the constructor, and whose
ErrorCode property is set to the value of the second integer passed
into the constructor.
|