This probably works:
Qt Code:
To copy to clipboard, switch view to plain text mode
Don't forget to free the BSTR, else you will get memory leaks!
This probably works:
Qt Code:
To copy to clipboard, switch view to plain text mode
Don't forget to free the BSTR, else you will get memory leaks!
Can you elaborate on the exact problem?
Show some code, debug messages?
But what happens when you use the suggested code?
Try:
std::wstring intermediateString(myBSTR, SysStringLen(myBSTR);
QString finalString = QString::fromStdWString(intermediateString);
-K
bmn (16th February 2012)
No need to use std:
QString qstr((QChar*)bstr, ::SysStringLen(bstr));
Bookmarks