Reference Library
CdKey Constructor (cdKey)
NamespacesMBNCSUtilCdKeyCdKey(String)
Creates a CD key decoder for the specified key.
Declaration Syntax
C#Visual BasicVisual C++
public CdKey(
	string cdKey
)
Public Sub New ( _
	cdKey As String _
)
public:
CdKey(
	String^ cdKey
)
Parameters
cdKey (String)
The CD key to initialize processing for.
Remarks

This constructor 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.

Exceptions
ExceptionCondition
ArgumentNullExceptionThrown if the value of cdKey is null (Nothing in Visual Basic).
ArgumentOutOfRangeExceptionThrown if the CD key is an invalid length or does not pass initial validity checks.

Assembly: Asgard5Library (Module: Asgard5Library)