View Single Post
Old 08-05-2019, 11:23 AM
d4okeefe d4okeefe is offline Windows 10 Office 2016
Advanced Beginner
Join Date: Apr 2013
Posts: 77
d4okeefe is on a distinguished road

You want to save an html as as word document?
I did this conversion with the following:

Sub saveHtmlAsDocx()
    Dim d As Document
    Set d = Documents.Open("C:\scratch\test.html")
    Dim newfile As String
    newfile = Replace(d, ".html", ".docx")
    d.SaveAs2 newfile, FileFormat:=wdFormatDocumentDefault
End Sub
Reply With Quote