Hello,
Please excuse the code below. I'm just hacking at the moment.
I have a question, essentially the below code displays 3 images.
The 1st image displays the background, and the remaining 2 smaller images are simple logos. It renders fine, however when I drag the dialog box. It fails to re-paint the background?
Could somebody be so kind and enlighten me on this problem and how to resolve it. My memory is indeed bad.
Thanks,
Garyc
void CtesterDlg::OnPaint()
{
CPaintDC dc( this ); CBitmap bmp, *poldbmp;
CDC memdc;
bmp.LoadBitmap(IDB_BITMAP1);
memdc.CreateCompatibleDC( &dc );
poldbmp = memdc.SelectObject( &bmp );
dc.BitBlt(0, 0,2000,4000, &memdc, 0, 0, SRCCOPY );
memdc.SelectObject( poldbmp );
bmp.LoadBitmap(IDB_BITMAP2);
memdc.CreateCompatibleDC( &dc );
poldbmp = memdc.SelectObject( &bmp );
dc.BitBlt(20,320,400,400, &memdc, 0, 0, SRCCOPY );
memdc.SelectObject( poldbmp );
bmp.LoadBitmap(IDB_BITMAP3);
memdc.CreateCompatibleDC( &dc );
poldbmp = memdc.SelectObject( &bmp );
dc.BitBlt(550,320,450,6000, &memdc, 0, 0, SRCCOPY );
}