I have an existing VB 6 application that opens an HTML document in Microsoft Word. When the user is finished with the document, the application converts the HTML file to a .doc, using wdFormatDocument in the SaveAs command to ensure it is saved as a Word Document file. The issue is the images. They are displaying fine in the HTML file being displayed in Word, however, after saving and closing the file and reopening the .doc file, they no longer display, just a red x placeholder is displayed. It appears, even though the file is converted to the Word Document format, it still wants to use the HTML references to point to the images in the file instead of embedding them in the Word Document.
To get around this the user needs to use "Insert...\Picture...\From File" and in effect replace the image with the same image again. Then it works fine after my VB application saves it as a Word Document. When the Word Document, .doc file is opened the images display fine.
My question is one or the other here. Is there a way to tell Microsoft Word when it saves the HTML document as a Microsoft Word Document to embed the images in the .doc file? Either that, or is there a way to search through the HTML document in Word and find each image and replace it with the same image file again?
Thank you for your help and suggestions.