CFrameWnd saving background as bitmap
Posted on 2004-03-23
I have subclassed a CFrameWnd, overridden OnPaint and in there I BitBlt some stuff to the window. I then save what i have done through a bitmap to a CDC object. I then continuing painting as i do not want to include this extra stuff in the DC. I only do this once ie
done = true;
This appears to work most of the time, but occasionally it is as if the wrong thing gets saved to the DC or I am saving before the frame is painted and i get a blank, white background with no images on it.
I am guessing what I am doing is not guaranteed to save the background, so how do I ensure what I am saving is what I want?
thanks for any help clarifying the situation.