Re: How to get SMTP address from Distinguished Name
From: Dmitry Streblechenko (dmitry_at_dimastr.com)
Date: 02/12/05
- Next message: lucy: "how to set up account protection for Outlook 2003?"
- Previous message: Dmitry Streblechenko: "Re: How to open Calendar C#"
- In reply to: asma.alam_at_gmail.com: "Re: How to get SMTP address from Distinguished Name"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 11 Feb 2005 18:54:23 -0700
1. No, Session.GetMessage does not display a prompt, so it must be something
else.
2. Where does the other address entry come from? If you only know the name,
use Namespace.CreateRecipients or Namespace.AddressLists to drill down to a
particular address list and find an entry in its contents table.
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
<asma.alam@gmail.com> wrote in message
news:1108156379.535507.3800@z14g2000cwz.googlegroups.com...
> Thanks Dimitry and Sue for that quick response. I can now get the SMTP
> addresses of all in the TO list using Redemption. However I still get
> the Outlook security prompt dialog.
>
> Presumably this happens when I detect the incoming objMsg As
> Outlook.MailItem and the code runs to convert it to a CDO message using
>
> objCDOMsg = objSession.GetMessage(strEntryID, strStoreID)
> before passing it onto the Redemption routines.
> How can I avoid such prompts? I cant have user interventions in my
> process.
>
>
> And secondly Can you please tell me how to change the following code to
> use the name of a person OTHER than the CurrentUser. It works fine to
> return the SMTP address of the CurrentUser so I was trying to use it
> return other users Smtp addresses, by somehow trying to impersonate
> another user but I'm not really sure how.
>
> Set objSession = CreateObject("MAPI.Session")
> objSession.Logon "", "", False, False
> Set objAddressEntry = objSession.CurrentUser
> strAddressEntryID = objAddressEntry.ID
> ' Get the SMTP address
> strEMailAddress =
> objSession.GetAddressEntry(strAddressEntryID).Fields(CdoPR_EMAIL)
>
> thanks again
> Asma
>
- Next message: lucy: "how to set up account protection for Outlook 2003?"
- Previous message: Dmitry Streblechenko: "Re: How to open Calendar C#"
- In reply to: asma.alam_at_gmail.com: "Re: How to get SMTP address from Distinguished Name"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|