Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Outlook, HTML and CDO
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00797784
Message ID:
00798158
Views:
38
>Sure. I often have to remove the html tags from web pages that
>I download or from Outlook messages. Usually I remove the html by
>importing a file into Excel than writing it as a dbf file. but this is
>relatively slow and since it looks like Ken Slovak has a way to strip
>the html codes from an Outlook Message directly, I thought that I would look
>into it. But what I really need is a fast html->plain text convertor.

Steve,

Try
FUNCTION Html2Text
LPARAMETERS tcHtml
LOCAL lcText
oWeb = createobject('InternetExplorer.Application')
WITH oWeb
  .Navigate("about:blank")
  .Document.Open()
  .Document.Write(tcHtml)
  .Document.Close()
ENDWITH
lcText = oWeb.Document.Body.OuterText
oWeb.Quit
RETURN lcText
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform