Solved

Embed Images in RTF when converting from HTML

Posted on 2001-08-21
5
972 Views
Last Modified: 2008-03-10
I'm converting an HTML doc to RTF using Word Automation and this works fine.  The problem is that the RTF file that is generated has linked images rather than embedded images.  How would I set this to save with embedded images so that the RTF file could be distributed without also having to include the images?
0
Comment
Question by:epeele
5 Comments
 
LVL 28

Expert Comment

by:AzraSound
ID: 6410731
Listening to hear if there is some property you can set in Word to do it...

Otherwise, you may consider doing it manually, by searching and replacing the links to those images, with the images themselves, via the OLEObjects.Add of a richtextbox.
0
 
LVL 14

Expert Comment

by:wsh2
ID: 6410812
<ping>
0
 
LVL 11

Accepted Solution

by:
thunderchicken earned 300 total points
ID: 6410948
I did this for about 3 months straight by writing a VB app to dynamically get information from the database to a word document.

To debug, I found what the error was, and manually fixed it through word.

1. Open the damaged document in word.

2. Go to Tools -> Macro -> Record New Macro

3. Call it what you want

4. Make the necessary changes

5. Go to Tools -> Macro -> Visual Basic Editor (If you have Visual Studio Installed)

This will give you the exact macro code you can directly integrate into your application.

I would go through and make a pattern of something similar, then encorporate it into VB code and it was that easy.
0
 
LVL 17

Expert Comment

by:inthedark
ID: 6412353
The following link describes embeded RTF Picture. There is also an example.  Hit the link and then search the page for "Pictures".

http://msdn.microsoft.com/library/?url=/library/en-us/dnrtfspec/html/rtfspec.asp?frame=true
0
 
LVL 4

Author Comment

by:epeele
ID: 6419989
Using the record macro in MSWord worked GREAT!  Thanks for the advice!
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now