
InternetUnicodeHTMLCSSScalable Vector Graphics (SVG)Extensible Markup Language (xml) ASPx TOCASP.NetMiscellaneous FeatureASP.NET ScriptingASP.NET Run-time Object System.Text.RegularExpressionsRegular Expression EngineRegular Expression Result PatternCharacter EscapesCharacter Classes
`-=[]โจโฉ\;',./~!@#$%^&*()_+{}|:"<>? ๐๐๐๐๐๐๐โ๐๐๐๐๐๐๐๐๐๐๐ ๐ก๐ข๐ฃ๐ค๐ฅ๐ฆ๐ง
ร
โโโรโโ
โยฑโ๊๏นฆโโ โฏ ๐ธ๐นโ๐ป๐ผ๐ฝ๐พโ๐๐๐๐๐โ๐โโโ๐๐๐๐๐๐๐โค๐ด๐ต๐ถ๐ท๐ธ๐น๐บ๐ป๐ผ๐ฝ๐พ๐ฟ๐๐๐๐๐๐
๐๐๐๐๐๐๐๐
โผโฝโพโโโโโ
โโโโโโโ โก โคโฅโฆโงโจโฉโชโซ
โโโโโโ โโโโ
โโ ๐ผ๐ฝ๐พ๐ฟ๐๐๐๐๐๐
๐๐๐๐๐๐๐๐๐๐๐๐๐๐
โโโโ
โฆฐโโโโโโดโต โโโโโโโ โงโจโฉโช
โซโฌโญโฎโฏโฐโฑโฒโณ โฅโฎโฏโฐโฑ โ โฒ โณ โด โ โ สน สบ โต โถ โท
๏น ๏น ๏น ๏น ๏ธน ๏ธบ ๏ธป ๏ธผ ๏ธ ๏ธ ๏ธฟ ๏น ๏ธฝ ๏ธพ ๏น ๏น ๏ธท ๏ธธ โ โ โด โต โ โ โ โก
โโโโโคโฆโฅโงโโโโโโโฒโผโโถโบโปโฒโณ โผโฝโพโฟโโโโโโ
โโ โโโโโโโโโโโโโโโณโฅขโฅฃโฅคโฅฅโฅฆโฅงโฅจโฅฉโฅชโฅซโฅฌโฅญโฅฎโฅฏ
Draft for Information Only
Content
Regular Expression Anchors
Regular Expression AnchorsAnchors, or atomic zero-width assertions, specify a position in the string where a match must occur. When using an anchor in a search expression, the regular expression engine does not advance through the string or consume characters; it looks for a match in the specified position only.
.NET AnchorsStart of String or Line: ^By default, the ^ anchor is used to specify that the following pattern must begin at the first character position of the string. If the ^ anchor is used with the RegexOptions.Multiline option, the match must occur at the beginning of each line. End of String or Line: $By default, the $ anchor is used to specify that the preceding pattern must occur at the end of the input string, or before \n at the end of the input string. If the $ anchor is used with the RegexOptions.Multiline option, the match can also occur at the end of a line. Note that $ matches \n but does not match \r\n (the combination of carriage return and newline characters, or CR/LF). To match the CR/LF character combination, include \r?$ in the regular expression pattern. Start of String Only: \AThe escaped \A anchor is used specify that the following pattern must occur at the beginning of the input string. It is identical to the ^ anchor, except that \A ignores the RegexOptions.Multiline option. Therefore, it can only match the start of the first line in a multiline input string. End of String or Before Ending Newline: \ZThe escaped \Z anchor is used to specify that the preceding must occur at the end of the input string, or before \n at the end of the input string. It is identical to the $ anchor, except that \Z ignores the RegexOptions.Multiline option. Therefore, in a multiline string, it can only match the end of the last line, or the last line before \n. Note that \Z matches \n but does not match \r\n (the CR/LF character combination). To match CR/LF, include \r?\Z in the regular expression pattern. End of String Only: \zThe escaped \z anchor is used to specify that the preceding pattern must occur at the end of the input string. Like the $ language element, \z ignores the RegexOptions.Multiline option. Unlike the \Z language element, \z does not match a \n character at the end of a string. Therefore, it can only match the last line of the input string. Contiguous Matches: \GThe escaped \G anchor is used to specify that the following pattern must occur at the point where the previous match ended. When you use this anchor with the Regex.Matches or Match.NextMatch method, it ensures that all matches are contiguous. Word Boundary: \bThe escaped \b anchor is used to specify that the match must occur on a boundary between a word character (the \w language element) and a non-word character (the \W language element). Word characters consist of alphanumeric characters and underscores; a non-word character is any character that is not alphanumeric or an underscore. (For more information, see Character Classes.) The match may also occur on a word boundary at the beginning or end of the string. The \b anchor is frequently used to ensure that a subexpression matches an entire word instead of just the beginning or end of a word. Non-Word Boundary: \BThe escaped \B anchor is used to specify that the match must not occur on a word boundary. It is the opposite of the \b anchor. ExamplesExamples of Anchors
ASP.NET Code Input: HTML Web Page Embedded Output: See also
Source/Reference
ยฉsideway ID: 190700027 Last Updated: 7/27/2019 Revision: 0 Ref: References
Latest Updated Links
Nu Html Checker 53 na |
![]() Home 5 Business Management HBR 3 Information Recreation Hobbies 9 Culture Chinese 1097 English 339 Travel 38 Reference 79 Hardware 55 Computer Hardware 259 Software Application 213 Digitization 37 Latex 52 Manim 205 KB 1 Numeric 19 Programming Web 290 Unicode 504 HTML 66 CSS 65 Selector 1 SVG 46 ASP.NET 270 OS 447 MS Windows DeskTop 7 Python 72 Knowledge Mathematics Formulas 8 Set 1 Logic 1 Algebra 84 Number Theory 207 Trigonometry 31 Geometry 34 Calculus 67 Engineering Tables 8 Mechanical Rigid Bodies Statics 92 Dynamics 37 Fluid 5 Control Acoustics 19 Natural Sciences Matter 1 Electric 27 Biology 1 |
Copyright © 2000-2026 Sideway . All rights reserved Disclaimers last modified on 06 September 2019