PackageUtilities.ConvertToType<T>(T, Type, CultureInfo) Method

Definition

Converts a string to an enumeration type.

public:
generic <typename T>
 where T : value class static System::Object ^ ConvertToType(T value, Type ^ typeToConvert, System::Globalization::CultureInfo ^ culture);
public static object ConvertToType<T> (T value, Type typeToConvert, System.Globalization.CultureInfo culture) where T : struct;
static member ConvertToType : 'T * Type * System.Globalization.CultureInfo -> obj (requires 'T : struct)
Public Function ConvertToType(Of T As Structure) (value As T, typeToConvert As Type, culture As CultureInfo) As Object

Type Parameters

T

The enum to convert to

Parameters

value
T

The enum value to be converted to

typeToConvert
Type

The type to convert

culture
CultureInfo

The culture to use to read the localized strings

Returns

Applies to