Gurus: Redemption Problem with Exchange 2003

S

Sanjay Singh

The following code is used to get an recipient's address. It needs to work
in both online and offline mode
The code worked perfectly with Exchange 2002. However it does not work in
offline mode with Exhcange 2003.

Set oSafeMail = CreateObject("Redemption.SafeMailItem")
oSafeMail.Item = oItem
Set oSafeRec = oSafeMail.Recipients(1).AddressEntry
strType = oSafeRec.Type
If strType = "EX" Then
'RecipientEmail = oSafeRec.Fields(&H39FE001E)

Addresses = oSafeRec.Fields(&H800F101E)
For i = LBound(Addresses) To UBound(Addresses)
If Left(Addresses(i), 5) = "SMTP:" Then
RecipientEmail = Right(Addresses(i), Len(Addresses(i)) - 5)
End If
Next
ElseIf strType = "SMTP" Then
RecipientEmail = oSafeRec.Address
End If

Set oSafeMail = Nothing
Set oSafeRec = Nothing


Any help will be greatly appreciated.

Thanks
Sanjay
 
D

Dmitry Streblechenko \(MVP\)

As long as your address book is available offline, PR_EMS_AB_PROXY_ADDRESSES
(&H800F101E) should be available, PR_SMTP_ADDRESS is generally not available
offline.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top