std::wstring holds a UTF-16 unicode string. It's methods are the same as those of std::string.
The standard library does not provide a conversion between unicode and ascii.
A standard string constant is defined as: L"This is a Unicode string constant."
There is a set of wide string operations in C. All the strXXX functions in C have wcsXXX equivalents that handle wide strings, e.g. wcslen() returns the length of a wide string.
Did you try the code L B posted? That really should work.
Here's a more simple test:
1 2 3 4 5 6 7 8
int main()
{
wchar_t buf[] = L"This should be displayed in the console.";
DWORD written;
WriteConsoleW( GetStdHandle(STD_OUTPUT_HANDLE), buf, sizeof(buf), &written, 0 );
return 0;
}
This should display the text in the console. Try that and see if it works.