So, I keep getting an assertion fail:
_AFXWIN_INLINE CDC* CWnd::GetDC()
{ ASSERT(::IsWindow(m_hWnd)); return CDC::FromHandle(::GetDC(m_hWnd)); }
And I checked the call stack and the method called before the method above is:
CDC *pDC = GetDC();
I'm not sure what is wrong with any of this, but I would like some help. Thanks!
m_hWnd
is bad but without seeing how it was created and such it's just a guess.CPaintDC
is a convenience, not a necessity. No application is ever required to instantiate aCPaintDC
.