The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.
KeyedHashAlgorithm::Key Property
.NET Framework (current version)
Gets or sets the key to use in the hash algorithm.
Assembly: mscorlib (in mscorlib.dll)
public: property array<unsigned char>^ Key { virtual array<unsigned char>^ get(); virtual void set(array<unsigned char>^ value); }
| Exception | Condition |
|---|---|
| CryptographicException | An attempt was made to change the Key property after hashing has begun. |
The following code example demonstrates how to override the Key property to retrieve the key used in the current KeyedHashAlgorithm object. This code example is part of a larger example provided for the KeyedHashAlgorithm class.
.NET Framework
Available since 1.1
Silverlight
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Available since 1.1
Silverlight
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Show: