C# Regex.Match exclude brackets -


I have to remove all the text inside and out of curly brackets.

This is my template @ {test.html} bla bla bla @ {test.html}

me test.html And va is the pattern I used

  \ @ [[AZA-Z.] *}  
< P> works fine but this curly bracket also returns. @ {test.html}, @ {test.html}

How to raise them.

The easiest way would be to use the group

  @ {([A-Za-z].] *)}  

If you do not want to do this

  (? & Lt; = @ {] [A-Za-z].] * (? =})  

Greetings

PS: Make sure you have everything in fact in your text to match any text - Group.


Comments

Popular posts from this blog

sqlite3 - UPDATE a table from the SELECT of another one -

c# - Showing a SelectedItem's Property -

javascript - Render HTML after each iteration in loop -