Jason, Could you use a CopyMemory(Dest, lpb, cb), where Dest is a pointer to
your widestring?

Dave.

-----Original Message-----
From: Jason L. Coley [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 25 October 2000 10:18
To: Multiple recipients of list delphi
Subject: RE: RE: [DUG]: PR_ENTRYID to Outlook Widestring EntryID?


The help on the PTBinary goes like this, so I doubt you could just cast
the TSBinary to a widestring.

An SBinary structure holds a pointer to a property value of type
PT_BINARY for use in an SPropValue structure holding information about a
property.
Syntax

typedef struct _SBinary
{
        ULONG   cb;
        LPBYTE  lpb;
} SBinary, FAR *LPSBinary;


Members

cb

Size, in bytes, of the data pointed to by the lpb member.

lpb

Pointer to the PT_BINARY property value.

Comments

The SBinary structure is defined in MAPIDEFS.H.

 -----Original Message-----
From:   Patrick Dunford [mailto:[EMAIL PROTECTED]] 
Sent:   Wednesday, 25 October 2000 10:08 a.m.
To:     Multiple recipients of list delphi
Subject:         RE: [DUG]:  PR_ENTRYID to Outlook Widestring EntryID?

can you cast the TSBinary to a widestring?

ie X = Widestring(T)

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of Jason L. Coley
> Sent: Wednesday, 25 October 2000 09:20
> To: Multiple recipients of list delphi
> Subject: [DUG]: PR_ENTRYID to Outlook Widestring EntryID?
> 
> 
> Hi,
> 
> I am working with an Outlook add-in, and I can't figure out how I can
> convert the EntryID that gets returned by the MAPI so it can be used
in
> Outlook to find an item.
> 
> I get the pointer to the msg item using the IMsgStore::OpenEntry
> function, which I can work OK, then make a call to get the Entry ID
> property using the GetProps call, which returns the values that I
want,
> but I can't figure out how to convert the TSBinary returned by MAPI to
a
> widestring that is used in Outlook?
> 
> Some rough code is below that I am using for testing. But the
conversion
> from the TSBinary to a WideString evades me completely.

======================================================================
Patrick Dunford, Christchurch, NZ - http://patrick.dunford.com/

   Correct me, LORD, but only with justice-- not in your anger,
lest you reduce me to nothing.
    -- Jeremiah 10:24
http://www.heartlight.org/cgi-shl/todaysverse.cgi?day=20001024
======================================================================
 
------------------------------------------------------------------------
---
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"

---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"
---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"

Reply via email to