Why would that be, they are not the same functions, one doesn't use the
other, they are just a conversion from the two formats, aren't they?
Jason
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
On Behalf Of Nello Sestini
Sent: Thursday, 26 October 2000 4:46 p.m.
To: Multiple recipients of list delphi
Subject: Re: RE: RE: Re: [DUG]: PR_ENTRYID to Outlook
Widestring EntryID?
Jason
I suspect that these will stop working the same time
the HrSzFromEntryID function is discontinued
-ns
-----Original Message-----
From: Jason L. Coley <[EMAIL PROTECTED]>
To: Multiple recipients of list delphi <[EMAIL PROTECTED]>
Date: Thursday, October 26, 2000 08:26
Subject: RE: RE: RE: Re: [DUG]: PR_ENTRYID to Outlook Widestring
EntryID?
I got the answer from Dmitry (the OutlookSpy creator), so if anyone is
interested the function is below.
function HexFromBin(lpb : pointer; cb : DWORD):string;
var HexStr:string;
i:integer;
begin
SetLength(Result,2*cb);
for i:=0 to cb-1 do begin
HexStr:=IntToHex(TByteArray(lpb^)[i], 2);
Result[2*i+1]:=HexStr[1];
Result[2*i+2]:=HexStr[2];
end;
end;
to convert it back, use:
function BinFromHex(hex : string):string;
var HexStr:string;
i:integer;
begin
SetLength(Result,Length(hex) div 2);
for i:=1 to Length(Result) do begin
HexStr:='$'+Copy(hex, 2*i-1, 2);
byte(Result[i]):=StrToInt(HexStr);
end;
end;
Its return value can be cast to PEntryID as
PEntryID(PChar(BinFromHexResult))
Dmitry
-----Original Message-----
From: Jason L. Coley
Sent: Wednesday, 25 October 2000 3:23 p.m.
To: Multiple recipients of list delphi
Subject: RE: RE: Re: [DUG]: PR_ENTRYID to Outlook Widestring
EntryID?
In fact I can't find any references to this function apart from in the
link below, and it does say that the function may be discontinued. The
only MapiUtil.h I can find has no reference to this function. Has anyone
used this call.
>Regards
>Jason Coley
>Manawatu Software Solutions
>http://www.software-solutions.co.nz
-----Original Message-----
From: Jason L. Coley
Sent: Wednesday, 25 October 2000 2:38 p.m.
To: Multiple recipients of list delphi
Subject: RE: Re: [DUG]: PR_ENTRYID to Outlook Widestring
EntryID?
Thanks for that, does anyone have the MAPIUtils.h file translated?
-----Original Message-----
From: Nello Sestini [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 25 October 2000 1:36 p.m.
To: Multiple recipients of list delphi
Subject: Re: [DUG]: PR_ENTRYID to Outlook Widestring EntryID?
Jason
> 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
there is a function (pardon my C++)
HrSzFromEntryID(ULONG cb, LPENTRYID lpEntryID,
LPTSTR FAR *lpsz);
in MAPI32.DLL that i think does what you want.
Have a look at:
http://msdn.microsoft.com/library/psdk/mapi/_mapi1book_hrszfromentryid.h
tm
-ns
------------------------------------------------------------------------
---
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"
------------------------------------------------------------------------
---
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"