Max Length for the EntryID property?

  • Thread starter Thread starter Dick
  • Start date Start date
There is no limit. Outlook will most likely start falling apart if it
greater than 32 kB (64 kB when converted to a hex string by the Uotlook
Object Model).
Practically however, 1000 or so characters should be sufficient.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 
hi,
Thanks very much for your useful help, but I found it has nearly been 64
bytes.
I just want to save the EntryID to a Access database, and as your know,
the max length of a String field is 255 bytes.
any suggestions?

Thanks!
Hanny
 
The length depends on the provider. E.g. store entry id under the PST
provider includes a full path to the PST file, which can exceed 255 bytes
when converted to hex.
Why can't you use a memo/blob field?

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 
hi,
Thanks for you reply, my purpose is to save the diskspace.
And now, I have another idear that I use MD5 to encode the EntryID, so the
length is still 32 bytes. Any suggestion would be appreciated.

thanks
Hanny
 
What will it be good for? You certainly won't be able to use it to call
Namespace.GetItemFromID
Any hashing is one way only - you can use it to figure out if a given entry
id is in the DB already, but you won't be able to retrieve the original
entry id given its hash.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 
Am Thu, 20 Oct 2005 11:34:56 +0800 schrieb Dick:

For saving diskspace once for an application I converted the StoreIDs from
unicode into ANSI with the StrConv function. This allows to store a 511
chars long id into the 255 limited field.

But
a) that you´ll have to pay with performance,
b) if an ID is longer than 511 then you´d have a problem :-)
 
Yes, I just want to judge whether the subitem exists or not, but
it will be paid with much more performance. :(

Now we get back to the original problem, seeing the following code:

Dim myNoteFolder As MAPIFolder
Dim myNote As NoteItem

Set myNoteFolder = Application.Session.GetDefaultFolder(olFolderNotes)
Set myNote = myNoteFolder.Items.Add(olNoteItem)

myNote.Body = "test1" & vbCrLf & "Line1"
myNote.Save
Debug.Print Len(myNote.EntryID); myNote.EntryID

I have tried it in more than 3 computers with this code, and got the same
result, the length of the EntryID were still 48 bytes!

Have you ever gotten an EntryID that it's more than 48 bytes?

Thanks again!
Hanny
 
Back
Top