tags:

views:

306

answers:

1

What is the difference between CString in vc6 and vc7?

+3  A: 

CString was removed from MFC in VC7 so that it could be used in both MFC and ATL projects. The architecture was completely changed:

  • In VC6, CString had no base class. In VC7, the base class is CStringT<TCHAR> which derives from CSimpleStringT<TCHAR>.
  • In VC7, you also get CStringA and CStringW for explicit char and wchar_t strings.

I'm not aware of any behavior differences between them, but the documentation is much easier to use in VC6. The methods are scattered between the base classes in VC7.

Mark Ransom