Hi,

I'm not sure what picturecontrl is, but should you not free the DC like this:


pThis->picturecontrl.ReleaseDC(pDC)