Top "Bstr" questions

`BSTR` stands for "Basic String". It is a size-prefixed, fixed-length, null-terminated, UTF-16 encoded character array used heavily in Microsoft's COM and OLE technologies for marshalling strings, especially between languages.

How to convert char * to BSTR?

How can I pass a char * from C dll to VB Here is sample code: void Cfunc(char *buffer,int …

c string com vb6 bstr
How to convert _bstr_t to CString

I have a _bstr_t variable bstrErr and I am having a CString variable csError. How do I set the …

c++ com mfc visual-c++ bstr
Convert BSTR to char*

Anyone know how to convert BSTR to char* ? Update: I tried to do this, but don't know if it is …

c++ visual-c++ char bstr
How would you convert a std::string to BSTR*?

How would you convert a std::string to BSTR*? STDMETHODIMP CMyRESTApp::rest(BSTR data, BSTR* restr) { RESTClient restclient; RESTClient::response …

c++ winapi bstr
How to best convert CString to BSTR to pass it as an "in" parameter into a COM method?

I need to convert a CString instance into a properly allocated BSTR and pass that BSTR into a COM method. …

windows visual-c++ com atl bstr
C++: Convert wchar_t* to BSTR?

I'm trying to convert a wchar_t * to BSTR. #include <iostream> #include <atlstr.h> using namespace …

c++ string com bstr
How to use BSTR*

I have an out value as BSTR* for an interface in a C++ COM dll. And I am returning this …

com bstr
How to pass BSTR to printf?

I have a non-unicode (MBCS) C++ project building with VS2013. Given a BSTR value, how should I pass this to …

c++ printf bstr