Does anybody know if you can use an object created with OleCreateFromFile more than once?
Posted on 2003-10-12 10:41:38 by Lennon
My 2 cents...

I fixed my above sample, but I see that in my absence better examples have been posted. Anyway, MSDN's code is useful only to embed files in a document... I tried embedding bitmaps, all I got was a little thumbnail that would launch the associated program when double clicked.

One of the links you posted had a solution to the problem of Paint being launched. However it involved (as I could understand) implementing your own interface, wich is not a trivial task from ASM. I won't have much free time this week (yet another exam next saturday :P ) but I was planning to study COM next week, so then I might be able to do something more useful... :)

As for the memory leak, it seems to be present in the "working" MFC code too. It seems that your app must remember all objects that were embedded, and release them "manually" before quitting. Odd... richedit should be taking care of that. (?)
Posted on 2003-10-14 17:51:18 by QvasiModo
Hi Qvasi,

Just about to go to bed and i noticed your post,

I thought everyone had given up on it, thank god your still trying to help :)

I also noticed the solution to the problem of Paint being launched, and the fact that mfc was involved :mad: the solution seems to have something to do with copying the bitmap to the clipboard...but even then i think it might have the same "memory leak"

I never would have thought it would be so hard to do something so...."simple" :confused:

I started this project to teach myself winsock. Winsock has been beautifully simple and fun to program, all my problems have been with richedit :mad:

I really need to find the solution before i die of frustration.

Thanks for all your help,
Posted on 2003-10-14 18:35:54 by Lennon