Author: NemoNemo Date: Apr 15, 2008 12:57
Hi. I am trying to insert an image into a RichEditCtrl, and was
following the code provided at MSDN KB 220844.
I seem to be getting stuck right at the first step. The assert
following the SendMessage always fails :
::SendMessage(m_ctlRichText.m_hWnd, EM_GETOLEINTERFACE, 0,
(LPARAM)&m_pRichEditOle);
ASSERT(m_pRichEditOle != NULL);
I tried to look up on MSDN, but I can't seem to find any documentation
as to why the attempt to get the interface might fail. Yet. I have a
funny feeling it is some initialization call that I must be missing.
btw, I do call AfxInitRichEdit(). I even stuck in a AfxOleInit() to be
sure.
Any insight, I'm sure, would be handy.
Thanks,
|