XML-db-console output and encoding


I work with Base X and try to integrate a XML database with c++ on Windows 7. I am using the BaseXclient API from https://github.com/JohnLeM/BasexCPPAPI/
it contains the pugixml parser and uses the boost lib. I got it to work but I have issues with the encoding. The xml dokuments in my database are utf-8 and contain some letters and symbols that are not displayed correctly on console output(like ä and °).
When I set #pragma execution_character_set( "UTF-8" ) its not working. I changed the locale with std::setlocale(LC_ALL, ""); in c++ and when I cout these symbols directly in my Programm and not from the database they are displayed correctly. The database output also changed but is still wrong.
I also set the pugi parser with pugi::xml_encoding::encoding_utf8; but the database output is not affected.
I use a string list for the database output. should I use wstring or is there something i missed? Can somone help me please?
The problem is of course the console which does not support utf8. setlocale(...) does not have any effect in this regard. You might try this:

Sorry I forgot to write that I have set the console code page. new strings in my c++ programm are displayed correctly in console. Only the string values from the database aren't displayed correctly.
Topic archived. No new replies allowed.