converting a string into a wstring code example Example: wstring to string std::string str(wstr.begin(), wstr.end());