Indicates that the given condition must not be true, throwing an
InvalidOperationException if it is.
Namespace: DotNetNuke.CommonAssembly: DotNetNuke (in DotNetNuke.dll)
Syntax
C# |
---|
public static void Against( bool condition, string message, params Object[] args ) |
Visual Basic |
---|
Public Shared Sub Against ( condition As Boolean, message As String, ParamArray args As Object() ) |
Parameters
- condition
- Type: System..::..Boolean
if set to true, throws an InvalidOperationException.
- message
- Type: System..::..String
A message that describes the error condition, as a composite format string (i.e. with {0} placeholders, like Format(String, array<Object>[]()[][])).
- args
- Type: array<System..::..Object>[]()[][]
An array of objects to fill in the placeholders in message.
Exceptions
Exception | Condition |
---|---|
System..::..InvalidOperationException | When condition is true |