L
lfvoydfv
Guest
I have an MFC project that uses CMemDC. When I build the project in release mode, I get an error saying "CMemDC::~CMemDC(void)" (??1CMemDC@@UAE@XZ) already defined in GridCtrl.obj" . There was an answer posted here MFC: linking error Solutions | Experts Exchange. I have a GridCtrl.cpp file that includes MemDC.h, which is a file in the project. According to the answer, CMemDC is already defined in stdafx.h so I don't need to include MemDC.h. But if I don't include MemDC.h in GridCtrl.cpp, I get an error the first time it declares a CMemDC object, saying that CMemDC is undefined even though stdafx.h is included in GridCtrl.cpp. What's strange is that when I build the project in debug mode, it builds fine, no errors. Thanks in advance for any answer as to what is going on.
Continue reading...
Continue reading...