CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Jun 2004
    Location
    USA
    Posts
    42

    Header for CString

    Hi
    I want to use CString in a console application. What header file shall I use?
    Thanks
    Fero

  2. #2
    Join Date
    May 2000
    Location
    Washington DC, USA
    Posts
    715

    Re: Header for CString

    file find in your mfc include directory for "class cstring". and you can find the exact include....

    or you could just hit f1 on the cstring object and see that the constructor tells you to include "afx.h"

  3. #3
    Join Date
    Apr 1999
    Posts
    27,449

    Re: Header for CString

    Quote Originally Posted by fero45
    Hi
    I want to use CString in a console application.
    Why? Use std::string and you don't need MFC.
    What header file shall I use?
    afxtempl.h, but seriously consider using the standard C++ classes and its containers for console apps, unless there is something in MFC that is absolutely unavailable or difficult to implement otherwise.

    Regards,

    Paul McKenzie

  4. #4
    Join Date
    May 2000
    Location
    KY, USA
    Posts
    18,652

    Re: Header for CString

    Besides that I agree with Paul...the following FAQ should help...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured