fw.Open(_T("1.txt"),CFile::modeWrite|CFile::typeText); 
请问其中_T是什么意思

解决方案 »

  1.   

    These data-type mappings are defined in TCHAR.H and depend on whether the constant _UNICODE or _MBCS has been defined in your program
      

  2.   

    如果定义了_UNICODE
    (_T("1.txt")  则"1.txt"在内部存储是采用双字节方式的。
      

  3.   

    _T你可以在VC里面goto define看看是什么意思的。
    这个是个字符串是unicode还是multi char的自动定义的宏。
    如果你编译的时候选了unicode的话那_T里面的字符串会被编译器转换为unicode的格式,如果没有定义那么就是多字节的定义。为了移植性,最好在字符串前面都加上这个。