I am working on a single project where I applied one conversion problem CStringWin CStringAfor a multibyte string such as Japanese.
I load a string from string resources using a method LoadString(). I tried the following code but it does not work.
CStringW csTest;
csTest.LoadString(JAPANESE_STRING);
CStringA Msg = CStringA(csTest); // Msg has been returned blank string
AND
std::string Msg = CW2A(csTest);
I also tried
wcstombs()too.
Can someone tell me how I can convert CStringWto CString? Thanks in advance.
source
share