Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
返されるのと同じように、.NET で正規表現キャプチャのオフセットを取得しようとしています.IndexOf()。とにかくそれを行うことはありますか?
.IndexOf()
の結果はオブジェクトRegex.MatchになりMatchます。その Index プロパティを確認します
Regex.Match
Match
Match m = Regex.Match(input, pattern); int i = m.Index;
h番目