< Dice | DiceException
Difference between revisions of "Dice/DiceException/DiceException (DiceErrorCode, Object)"
From DiceRoller Documentation
 (Created page with "{{APIdoc|DiceException Constructor (DiceErrorCode, Object)}} Constructs a DiceException for the given DiceErrorCode using the given object as its parame...")  | 
			
(No difference) 
 | 
Latest revision as of 18:07, 12 April 2017
Constructs a DiceException for the given DiceErrorCode using the given object as its parameter.
- Namespace: Dice
 - Assembly: DiceRoller (in DiceRoller.dll)
 
Syntax
public DiceException(
    DiceErrorCode error,
    object param
)
Parameters
- error
 - Type: Dice.DiceErrorCode
 - What error this exception represents.
 
- param
 - Type: System.Object
 - Format parameter for the error code's associated message.
 
Remarks
The exception's Message property is initialized to the description string of the DiceErrorCode, passing param in a String.Format call to fill in {0}. These strings match what is shown on the documentation page's member list. This overload should not be used if the description string does not contain the format parameter {0}, use the DiceException(DiceErrorCode) overload instead.