Uri.IsHexDigit メソッドとは? わかりやすく解説

Uri.IsHexDigit メソッド

指定した文字が有効な 16 進数の数字かどうかを判断します。

名前空間: System
アセンブリ: System (system.dll 内)
構文構文

解説解説

16 進数の数字とは、0 ~ 9 の数字と、A ~ F または a ~ f の文字です。

使用例使用例

文字が 16 進文字かどうかを判断し、16 進文字である場合は対応する 10 進値をコンソールに出力する例を次に示します。

Dim testChar As Char = "e"c
If Uri.IsHexDigit(testChar) = True Then
    Console.WriteLine("'{0}' is the hexadecimal representation
 of {1}", testChar, Uri.FromHex(testChar))
Else
    Console.WriteLine("'{0}' is not a hexadecimal character",
 testChar)
End If 
Dim returnString As String
 = Uri.HexEscape(testChar)
Console.WriteLine("The hexadecimal value of '{0}'
 is {1}", testChar, returnString)
char  testChar = 'e';
if (Uri.IsHexDigit(testChar) == true)
    Console.WriteLine("'{0}' is the hexadecimal representation of {1}",
 testChar, Uri.FromHex(testChar));
else 
    Console.WriteLine("'{0}' is not a hexadecimal character", testChar);

string returnString = Uri.HexEscape(testChar);
Console.WriteLine("The hexadecimal value of '{0}' is {1}", testChar, returnString);
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照



英和和英テキスト翻訳

英語⇒日本語日本語⇒英語

辞書ショートカット

すべての辞書の索引

「Uri.IsHexDigit メソッド」の関連用語

Uri.IsHexDigit メソッドのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



Uri.IsHexDigit メソッドのページの著作権

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2026 Microsoft.All rights reserved.

©2026 GRAS Group, Inc.RSS