Hi Experts,
Our application needs to load a file into a std::ifstream object. The filename contains Slovenian characters - i.e. Latin Small Letter Z with Caron. (U+017E). Assume that I have the filename in a std::wstring object, how can I open a std::ifstream object and associate it wiith that filename?
For example:
std::wstring filename;
std::ifstream sin(filename.c_str(), std::ios::in | std::ios::in | std:::ios::binary | ios_base::ate);
Doing this gives me a compile error that it cannot convert parameter 1 from const wchar_t * to const char *
What is the best way of doing this?
Start Free Trial