Potresti escludere le porzioni di testo comprese tra i tag <nocode> e </nocode> PRIMA di applicare le regexp, per esempio con questa funzioncina:
codice:
function RemoveNocodeTags(txt)
dim tmptxt
tmptxt = txt
if IsNull(tmptxt) then
exit function
end if
dim i, pos1, pos2
do
pos1 = Instr(tmptxt, "<nocode>")
if pos1=0 then
exit do
else
pos2 = Instr(pos1, tmptxt, "</nocode>")
if pos2=0 then
exit do
else
tmptxt = Left(tmptxt, pos1-1)&Mid(tmptxt, pos2+9)
end if
end if
loop
RemoveNocodeTags = tmptxt
end function
in modo che, se il tuo testo è
il tuo testo senza la parte tra i tags <nocode> e </nocode> sarà:
codice:
testofiltrato = RemoveNocodeTags(testo)
Poi, sul testofiltrato, applicherai le regexp..........