do u mean the problem come form
1 2
|
string filename = (cur_dir , ":\\expggds\\" + filename2) ;
LPCTSTR filename_LP = filename.c_str();
|
string uses char ;
LPCTSTR uses TCHAR ; --> due to i use unicode --> LPCTSTR -> TCHAR -> wchar_t
so , i can not put filename(string, char, ANSI) to filename_LP (LPCTSTR , TCHAR, unicode, wchar_t)
char_t -->wchar_t
it's all about space probelm / wchar_t and char problem
T stands for TCHAR. On Windows, a TCHAR is either char or wchar_t , which depending on do UNICODE is #defined by the preprocessor ~~
The idea is it lets you to use a same variable , before u don't know whether user will input a ANSI or Unicode characters.
1. std::string is ansi and std::wstring is its UNICODE counter part.
2. When unicode is defined, LPCTSTR stands for wchat_t.
3. That's why I have error in line - LPCTSTR filename_LP = filename; i.e. Unicode = Ansi
just have a note of it ,
thanks all of you