This documentation is archived and is not being maintained.

Uri.HexUnescape Method

Converts a specified hexadecimal representation of a character to the character.

[Visual Basic]
Public Shared Function HexUnescape( _
   ByVal pattern As String, _
   ByRef index As Integer _
) As Char
public static char HexUnescape(
 string pattern,
   ref int index
public: static __wchar_t HexUnescape(
 String* pattern,
 int* index
public static function HexUnescape(
   pattern : String,
 index : int
) : Char;


The hexadecimal representation of a character.
The location in pattern where the hexadecimal representation of a character begins.

Return Value

The character represented by the hexadecimal encoding at position index. If the character at index is not hexadecimal encoded, the character at index is returned. The value of index is incremented to point to the character following the one returned.


Exception Type Condition
ArgumentOutOfRangeException index is less than 0 or greater than or equal to the number of characters in pattern.


Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework, Common Language Infrastructure (CLI) Standard

See Also

Uri Class | Uri Members | System Namespace