MachineKeyValidationConverter.ConvertFrom Method

Definition

Converts a string to the equivalent MachineKeyValidation value.

public:
 override System::Object ^ ConvertFrom(System::ComponentModel::ITypeDescriptorContext ^ ctx, System::Globalization::CultureInfo ^ ci, System::Object ^ data);
public override object ConvertFrom (System.ComponentModel.ITypeDescriptorContext ctx, System.Globalization.CultureInfo ci, object data);
override this.ConvertFrom : System.ComponentModel.ITypeDescriptorContext * System.Globalization.CultureInfo * obj -> obj
Public Overrides Function ConvertFrom (ctx As ITypeDescriptorContext, ci As CultureInfo, data As Object) As Object

Parameters

ctx
ITypeDescriptorContext

This parameter is not used.

ci
CultureInfo

This parameter is not used.

data
Object

The string to convert.

Returns

The equivalent MachineKeyValidation value.

Exceptions

The data is not one of the expected strings.

Remarks

This method will throw an ArgumentException exception if the data parameter does not refer to one of the following strings:

  • SHA1

  • MD5

  • 3DES

  • AES

Applies to