How do I create a macro in VBA (Word) that will run through:
<ul><li>this is just a test</li><li>woop</li><li>test</li></ul>
and generate a
- this is just a test
- woop
- test
Using Word 2010.
Reason for this is the html comes in via mailmerge from a 3rd party system.
This HAS to be done through a macro for my endusers! :)
More Details: I will have to create something as the following that searches for the Italic html tag and inserts Font.Italic instead.
With ActiveDocument.Range.Find
.ClearFormatting
.MatchCase = False
.MatchWildcards = True
.Text = "[<][iI][>]*[<]/[iI][>]"
.Replacement.Font.Italic = True
.Execute Replace:=wdReplaceAll
End With
So my question is, how do I, like this, run through the document and finds the <ul>
instance and loops through each of the <li>
tags and inserts the text in the tag as a bulleted list...