I have a paragraph as shown below:
Some wording for testing [! #today], where the condition [!] does not satisfy this wording [! ShowElemIf: // Student / FullName; [[[Text is not fully recognized]]]; / Name] But simple tags with age [! ShowElemIf: // Student / Age; xml // Student / DOB / @ formatted; y]
I need to find all the tags / tags on top that are: [! tag] use C #. I tried to create a regular expression, but could not find a tag that has the word "FullName" in bold.
List<string> tags = Regex.Matches(
sampleText.Replace(Environment.NewLine, ""), @"\[!([^]]+)\] ")
.Cast<Match>()
.Select(x => x.Groups[1].Value)
.ToList();
Run codeHide resultUsing this RegEx, I can find below, but not highlighted.
- Today
- state
- ShowElemIf: // Student / Age, XML // Student / DOB / @ formatted, y