NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Convert.ToChar (String)

Converts a non-empty String of length 1 to a character.

[Visual Basic]
Overloads Public Shared Function ToChar( _
   ByVal value As String _
) As Char
[C#]
public static char ToChar(
   string value
);
[C++]
public: static __wchar_t ToChar(
   String* value
);
[JScript]
public static function ToChar(
   value : String
) : Char;

Parameters

value
The number to be converted.

Return Value

The character at index 0 within value .

Exceptions

Exception Type Condition
ArgumentException If value is null.

If value is not a string of length 1.

FormatException If value is not a string of length 1 or is String.Empty.

See Also

Convert Class | Convert Members | System Namespace | Convert.ToChar Overload List