Home All Groups Group Topic Archive Search About

Removing HTML tags from a text selection

Author
8 Mar 2006 8:20 PM
Bill
I have an html file open on an rtftextbox in my project.

Can you  point me to some code that would show and easy way to remove
the HTML tags?

Thanks.

Author
8 Mar 2006 8:27 PM
dNagel
If you're willing to use regular expressions, the sequence below will
locate them for you...  translating that into VBScripts' RegEx
functions is up to you ;-)

<([A-Z][A-Z0-9]*)\b[^>]*>(.*?)</\1>

http://www.regular-expressions.info/regexbuddy/htmltagpairany.html

D.



Bill wrote:
Show quoteHide quote
> I have an html file open on an rtftextbox in my project.
>
> Can you  point me to some code that would show and easy way to remove
> the HTML tags?
>
> Thanks.
Author
9 Mar 2006 12:44 PM
Tony Proctor
Try this one-liner Bill:
http://groups.google.ie/group/microsoft.public.sqlserver.programming/msg/a83b34c30f46adf8?&hl=en

    Tony Proctor

Show quoteHide quote
"Bill" <Bill12***@google.com> wrote in message
news:27fu02d03v36bcqrr2nj17pjeii6gpgeb1@4ax.com...
> I have an html file open on an rtftextbox in my project.
>
> Can you  point me to some code that would show and easy way to remove
> the HTML tags?
>
> Thanks.