Solved

How do I convert an EMF image to RTF file?

Posted on 2009-04-14
9
630 Views
Last Modified: 2012-05-06
Hi,

As I didn't find it on the web, I'd like to develop a tool to convert emf files into rtf.

Does anyone have an idea to embed the image in an rtf file with C# code ?

Thanks in advance
0
Comment
Question by:JulienVan
  • 4
  • 3
9 Comments
 
LVL 39

Accepted Solution

by:
abel earned 500 total points
ID: 24139048
EMF (Enhanced MetaFile) is used for spooling and sometimes for images and is a binary format. In general, image formats cannot be converted to word-processor formats, unless you use some type of OCR package to extract the readable text from the EMF.

RTF (Rich Text Format) is a format (text-based, not binary) to write markup of word-processing documents. It can contain EMF files as embedded objects and it can be viewed if the reader of the RTF file contains a viewer for EMF, but they cannot be converted.

-- Abel --
0
 
LVL 2

Author Comment

by:JulienVan
ID: 24139109
Hi abel, thanks for your comment.
I'd like to embed the image in a rtf file, would you know a way to do that with C# code?
0
 
LVL 2

Author Comment

by:JulienVan
ID: 24139404
I'm going to create the rtf documents with office automation, by opening word, creating a new document, paste the image, and save as rtf.
If anybody has another idea, thanks in advance.
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 39

Assisted Solution

by:abel
abel earned 500 total points
ID: 24139429
That's a good way of doing it, of course, but if you want to bundle it you can only have your program used by people having Office. I wouldn't mind trying the EMF embedding for you, shouldn't be too hard in C# or any other .NET language.
0
 
LVL 39

Expert Comment

by:abel
ID: 25185963
This q. was answered in the first comment, which covers that EMF is not a good choice for embedded images in RTF and should be avoided. Please accept http:#24139048 as answer.
0
 
LVL 39

Expert Comment

by:abel
ID: 25193940
See my prev. comment, please. There are no other experts on this thread, no need to wait for them ;-)
0
 
LVL 2

Author Closing Comment

by:JulienVan
ID: 31569942
Sorry for the delay abel, all your comments were accurate so I accept them as multiple solutions.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Need to pass stored proc parameters in list 13 32
Need a complete list of ASP.NET page load events 3 25
Export import database 4 40
Excel 2016 Not Responding Issues 6 22
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Learn how to create and modify your own paragraph styles in Microsoft Word. This can be helpful when wanting to make consistently referenced styles throughout a document or template.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

932 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

12 Experts available now in Live!

Get 1:1 Help Now