native c++ does not support CString -- that is a MFC c++ class. The cstring header file you included is the same as C's string.h, which is not at all like CString or c++ string.
>>what is the problem?
include <string> header file and use std::string object.
If you are using the Pro edition of that compiler I think you can create a console project that suports MFC non-visual classes such as CString. I know VC++ 6.0 does it, but not sure about VC++ 2005 Pro or newer compilers[/edit]
Since you are developing a Win32 Console Application, you don't get the boiler plate code that gets added for different project types.
Please include <atlstr.h> in your code after the pre-compiled headers.
Hope this resolves the issue.
If you directly access the CString variable in a Win32 console application, you will get the address and not the content. In order to access the content of the variable you need to convert it to a native C++ type (for eg: std::string). My suggestion is to use std::string instead it is absolutely necessary to use CString. It is very much possible to use CString but not recommended due to conversion overhead. Pick your choice.