std::string to LPCTSTR

后端 未结 7 1305
甜味超标
甜味超标 2021-02-19 10:30

New version of the typical question of how to convert from std::string to LPCTSTR.

Reading from different SO posts I learnt that I should do th

7条回答
  •  不思量自难忘°
    2021-02-19 11:20

    Your problem here is the fact that LPCTSTR is resolved to wchar_t* or char* based on whether your build supports unicode (unicode flag set or not).

    To explicitly call the char* version, call CreateDirectoryA().

提交回复
热议问题