Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 11-21-2014, 01:53 PM
john1 john1 is offline Save HTML as DOCX Windows 8 Save HTML as DOCX Office 2013
Novice
Save HTML as DOCX
 
Join Date: Nov 2014
Posts: 1
john1 is on a distinguished road
Default Save HTML as DOCX

I have html files on my C drive containing pictures. It opens correctly in a web browser. I open it in word 2013 and then try to save it as a docx. It saves a docx but the file is only 200 bites, instead of the 75MB it should be. The docx does open correctly and look good but if I delete the html, the docx no longer opens.

How do I save as a self contained docx?
Reply With Quote
  #2  
Old 11-21-2014, 10:56 PM
gmayor's Avatar
gmayor gmayor is offline Save HTML as DOCX Windows 7 64bit Save HTML as DOCX Office 2010 32bit
Expert
 
Join Date: Aug 2014
Posts: 4,106
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

The images are converted to links to the original images, links which cannot be viewed in Word 2013, so you need a two step process.

First save as Word 97-2003 DOC format (in a folder other than that containing the HTML files), then run the following macro to unlink the images:

Code:
Sub UnlinkImages()
Dim ofld As Field
    For Each ofld In ActiveDocument.Fields
        ofld.Unlink
    Next ofld
End Sub
Then finally save as DOCX with the images embedded.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
Reply

Tags
convert, docx, html



Similar Threads
Thread Thread Starter Forum Replies Last Post
2013 docx to html image issue iggyb Word 0 08-18-2014 08:44 AM
Save HTML as DOCX After Word crash, can no longer save as .docx mrwednesday Word 4 10-15-2013 01:21 AM
Save HTML as DOCX How can I set *.doc as default save format and NOT *.docx? pstein Word 1 01-11-2012 09:30 AM
Save HTML as DOCX Can't Save a file as .docx the_lil Word 5 10-27-2011 08:41 AM
Save HTML as DOCX Save Word doc in unicode html (utf-8) rybrns Word 5 09-26-2011 02:18 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:13 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft