Forum: Ruby Re: BSTR data type

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
F3b7b8756d0c7f71cc7460cc33aefaee?d=identicon&s=25 Berger, Daniel (Guest)
on 2006-05-03 18:57
(Received via mailing list)
> (at least directly).  Does anyone have code to do so?  How
> about the variant data type?  (I am not talking about COM
> server libraries that could be called with Win32OLE.)

BSTR is a wide string, so your declaration would be 'P' (or
'L' if you plan on passing addresses around).

I've never dealt with BSTR directly, but it looks like you may
have to manipulate your strings with MultiByteToWideChar() and
WideCharToMultiByte() first, before passing them to whatever
function you use that requires BSTR data types.

If you can provide an example of something you're having
trouble with we can probably help you better.



This communication is the property of Qwest and may contain confidential
privileged information. Unauthorized use of this communication is
prohibited and may be unlawful.  If you have received this communication
in error, please immediately notify the sender by reply e-mail and
all copies of the communication and any attachments.
This topic is locked and can not be replied to.