KGy SOFT

EnumTEnumToString Method (TEnum, EnumFormattingOptions, String)

KGy SOFT Core Libraries Help
Returns the String representation of the given enum value specified in the value parameter.

Namespace:  KGySoft.CoreLibraries
Assembly:  KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 5.0.0-rc.1
Syntax

public static string ToString(
	TEnum value,
	EnumFormattingOptions format = EnumFormattingOptions.Auto,
	string separator = ", "
)

Parameters

value
Type: TEnum
A TEnum value that has to be converted to String.
format (Optional)
Type: KGySoft.CoreLibrariesEnumFormattingOptions
Formatting option. This parameter is optional.
Default value: Auto.
separator (Optional)
Type: SystemString
Separator in case of flags formatting. If  or is empty, then comma-space (, ) separator is used. This parameter is optional.
Default value: , .

Return Value

Type: String
The string representation of value.
Exceptions

ExceptionCondition
ArgumentOutOfRangeExceptionInvalid format.
See Also

Reference