digitalmars.D.learn - convert and assign to the BSTR char
hi, how does one convert char[] to BSTR and back? i am looking to use a dll that contains function such as BSTR tester = gettest(BSTR *in, BSTR in1); any help is appreciated.
Apr 18 2009
new Wrote:hi, how does one convert char[] to BSTR and back? i am looking to use a dll that contains function such as BSTR tester = gettest(BSTR *in, BSTR in1); any help is appreciated.wchar* bstr = SysAllocString(std.utf.toUTF16z(s)); and char[] s = std.utf.toUTF8(bstr[0 .. SysStringLen(bstr)]); SysFreeString(bstr);
Apr 18 2009