[ the jinxbot project :: home | community forum | bn# | controls | mbncsutil | get the source ]
Assembly: MBNCSUtil (in MBNCSUtil.dll) Version: 2.1.7.22 (2.1.7.22)
Creates a CD key decoder for the specified key.
Namespace:
MBNCSUtilAssembly: MBNCSUtil (in MBNCSUtil.dll) Version: 2.1.7.22 (2.1.7.22)
Syntax
| C# |
|---|
public static CdKey CreateDecoder( string key ) |
| Visual Basic (Declaration) |
|---|
Public Shared Function CreateDecoder ( _ key As String _ ) As CdKey |
| Visual C++ |
|---|
public: static CdKey^ CreateDecoder( String^ key ) |
Parameters
- key
- Type: System..::.String
The CD key to initialize processing for.
Return Value
An instance of the CdKey class
Remarks
This method only conducts initial validity checks to ensure that the CD key is valid; that is, it checks for a valid key length (13, 16, or 26 characters) and checks that the characters are valid for the key type. For example, Starcraft keys are numeric only, whereas Warcraft II, Diablo II, Lord of Destruction, Warcraft III, and The Frozen Throne keys are alphanumeric.
Additional validity checks are conducted internally; however, these do not raise Exceptions. To confirm the validity of a key after instantiation, call the CdKey.IsValid property.
This method is only a wrapper for the CdKey constructor and provides no additional functionality.
Exceptions
| Exception | Condition |
|---|---|
| System..::.ArgumentNullException | Thrown if the value of key is null (Nothing in Visual Basic). |
| System..::.ArgumentOutOfRangeException | Thrown if the CD key is an invalid length or does not pass initial validity checks. |