Hi everybody.
My task is to convert a bmp or jpg image to metafile and export it to MS word. I can convert the bmp image by saving it in wmf format but if I try to load that wmf file I wil get the "GDI+ general purpose exception". Please tell me how to do it.
Or Tell me how can I embed bitmap in metafile.
Nathan

Mahesh ChandRank #1 · 393.4K reputationPosted Jul 9, 2008, 11:31 AM EDT
Nathan NZ15 reputationPosted Jul 9, 2008, 6:26 PM EDT
Thanks for the reply Mahesh.
I have gone through the Metafile and Bitmap Class.
MSDN says GDI+ do not allow you to create wmf from bitmaps. It said
"When you use the Save method to save a graphic image as a Windows Metafile Format (WMF) or Enhanced Metafile Format (EMF) file, the resulting file is saved as a Portable Network Graphics (PNG) file instead. This behavior occurs because the GDI+ component of the .NET Framework does not have an encoder that you can use to save files as .wmf or .emf files."
But after googling I came to know that we can embed bitmap in a metafile. So I was trying to do that. As I dont know OLE, I posted it on the web.
Please correct if I am wrong.
algates sunda3 reputationPosted Aug 3, 2008, 9:46 PM EDT