views:

31

answers:

1

Does any one know how to find following string using regular expression of visual studio?

  <fo:block>

  </fo:block>

I have tried with following but it didn't work

\<fo\:block\>*$\n*\</fo\:block\>$
+2  A: 

This works for me but it's not pretty...

\<fo\:block\>.*\x0d\x0a.*\x0d\x0a.*\<\/fo\:block\>

I thought I tried this:

\<fo\:block\>.*\n.*\n.*\<\/fo\:block\>

yesterday but apparently I didn't because it works.

Jonas Elfström
could you explain a about \x0d\x0a.*\x0d\x0a
Thunder
x0d = CR (Carriage Return) and x0a = LF (Linefeed) but now it seems \n works just as fine.
Jonas Elfström