On 08/19/2012 03:43 PM, jicman wrote:
>
> Greetings.
>
> I am trying to pass a (I think) dchar value to a Windows COM
> function and it does not work.  Imagine this situation...
>
> dchar test()
> {
>    dchar val = 0x00000000;
>    return val
> }
>
> void main()
> {
>    ...lots of code excluded
>    SomeWindowsComCall(test); // this call does not work
>    SomeWindowsComCall(0x00000000); // this call works
> }
>
> Any idea how I can create a function to be able to return values
> such as 0x00000000 .. 0x0000FFFF?
>
> Thanks.
>
> jos�

How about using dchar literals:

  http://digitalmars.com/d/1.0/expression.html#CharacterLiteral

dchar test()
{
    return '\U00000000';
}

Ali

Reply via email to