CString with ATL/WTL 7.0
-
I've got an app, generated with the ATL app wizard in VC7. Now it was compiling fine, until I added a CSting object to a function, and now it gets upset, saying it does not know what one is, yet I know CString is in ATL now. Any ideas what could be happening? I'm getting error C2065 - undeclared identifier. Anyone know which header file its in so I can include it explicitly?
-
I've got an app, generated with the ATL app wizard in VC7. Now it was compiling fine, until I added a CSting object to a function, and now it gets upset, saying it does not know what one is, yet I know CString is in ATL now. Any ideas what could be happening? I'm getting error C2065 - undeclared identifier. Anyone know which header file its in so I can include it explicitly?
It's quite obvious - and mentioned in the help for CStringT ;)
#include <atlstr.h>
Bjørn. -
It's quite obvious - and mentioned in the help for CStringT ;)
#include <atlstr.h>
Bjørn. -
I've got an app, generated with the ATL app wizard in VC7. Now it was compiling fine, until I added a CSting object to a function, and now it gets upset, saying it does not know what one is, yet I know CString is in ATL now. Any ideas what could be happening? I'm getting error C2065 - undeclared identifier. Anyone know which header file its in so I can include it explicitly?
Also, if you even include (which defines the WTL CString, CRect, etc.) then it may conflict with the ATL7 version. If you want to use the ATL7 CString AND you still need then do the following in stdafx.h: #define _WTL_NO_WTYPES #define _WTL_NO_CSTRING #include <atlmisc.h>
Faith. Believing in something you *know* isn't true.
-
Also, if you even include (which defines the WTL CString, CRect, etc.) then it may conflict with the ATL7 version. If you want to use the ATL7 CString AND you still need then do the following in stdafx.h: #define _WTL_NO_WTYPES #define _WTL_NO_CSTRING #include <atlmisc.h>
Faith. Believing in something you *know* isn't true.