LPOLESTR* to string

Andre andre at s-e-a-p.de
Mon Feb 10 09:08:27 PST 2014


Am 10.02.2014 17:53, schrieb Mike Parker:
> On 2/11/2014 1:32 AM, Andre wrote:
>> Hi,
>>
>> one hour trying to get a string out of LPOLESTR*.
>> What is the correct command to get rgszNames as string?
>>
>> HRESULT GetIDsOfNames(REFIID riid, LPOLESTR* rgszNames, UINT cNames,
>> LCID lcid, DISPID* rgDispId){}
>>
>> With following command I only get the first character
>> writeln(to!string(**rgszNames));
>>
>> Kind regards
>> André
>
> I would assume to!string(*rgszNames). Assuming LPOLESTR is char* or some
> such, then LPOLESTR** is char**, so **LPOLESTR would be the first
> character in the string, and *LPOLESTR would be the char* string.


to!string(*rgszNames) outputs a number instead of a name.
I think I am a step further, rgszNames is an array but also with 
to!string(*rgszNames[0]) only the first character of my method is given 
back.

Kind regards
André


More information about the Digitalmars-d-learn mailing list