Information générale
Catégorie:
COM/DCOM et OLE Automation
Titre:
Passing BSTRs to/from VFP8
I wrote a serial comm server DLL using ATL (MS C++ Ver. 6). A test program using VB 6 works fine - I can pass and receive BSTRs (Unicode) back and forth.
Things aren't so easy when VFP8 is the client. I can send a BSTR from FoxPro to the server DLL if the server method takes a BSTR argument (but not if the server method takes a BSTR* argument).
I'd like to be able to pass a variable length Unicode BSTR back to FoxPro because I can't tell in advance how long the string will be. The prototype for my C++ method that returns the string to FoxPro is:
STDMETHODIMP CSerialClass::GetSerialData(BSTR* sData);
Is there a way to do this. I saw somewhere in the documentation that FoxPro does not support Unicode (if this is true, then why does Microsoft push Unicode as the next frontier?)
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement