Imported DLL function returns chinese characters (wrong encoding?)
Can you elaborate please? Any tip how to convert so I can read it?
Never mind. I resolved it.
Essentially, if the imported DLL function (written in C++) returns char* then you'll see the weird characters that I have seen.
I was lucky enough so that the C++ library I use is open source and I could modify the C++ source code and rebuild the DLL.
In C++ I changed the function to return wchar_t* - this way the output in MQL5 is correct.
It'd be nice if there were more data types available in MQL5 or a way to convert the weird string.
I am trying to integrate TDLib in an EA to create a Telegram message reader expert.
I have built the TDLib library (Windows 10) and included it.
It seems to work, but the response seems different encoding and so I cannot interpret it and cannot figure out how/where to convert it.
mq5:
output:
Any ideas?