I'm currently writing a nickname saver in C++ (on request from dakillerspyder), but I'm having trouble with Messenger's get_MyFriendlyName() method. The method takes a single argument, a BSTR*.
here is the code I'm currently using:
code:
char* nick;
BSTR nickTemp;
hMessenger->get_MyFriendlyName(&nickTemp);
nick = (char*)nickTemp;
This successfully gets me the first character, but only the first character. How do I get the rest of the nickname?
UPDATE: Found the problem (bloody Unicode!)
UPDATE 2: Fixed! I wrote my own conversion routine.