Solved

using .Addressbook from MAPI.Session object

Posted on 2004-10-13
5
2,066 Views
Last Modified: 2012-05-05
I have an Exchange 2000 server
Client is Outlook 2003
I have a custom form that is published to the Organizational Forms Library and is not 1 offed.
All the docs I can find say that if it is published in Org Lib then Outlook Security Blocks will be bypassed but I am finding the exact opposite, works a treat in Outlook 2002 but security prompts in 2003.

Can anyone shed some light on this ... please ???

TIA,
Steve

Private Function GetRecipients()

Dim outRecipients            'collection of recipients
Dim outRecipient            'single recipient
Dim strRecipients            'string of recipient names
Dim n                  'integer

On Error Resume Next
If moutSession Is Nothing Then
   Set moutSession = CreateObject("mapi.session")
   moutSession.Logon , , False, False
End If

Set outRecipients = moutSession.Addressbook
strRecipients = ""

For n = 1 To outRecipients.Count
   Set outRecipient = outRecipients.Item(n)
   strRecipients = strRecipients & outRecipient.Name & ";"
Next
If Len(strRecipients) <> 0 Then
   strRecipients = Left(strRecipients, Len(strRecipients) - 1)    'Remove last ";"
   GetRecipients = strRecipients
Else
   GetRecipients = ""
End If

Set outRecipients = Nothing
Set outRecipient = Nothing

End Function
0
Comment
Question by:stevbe
  • 2
5 Comments
 
LVL 39

Accepted Solution

by:
stevbe earned 0 total points
ID: 12298439
it was not the code ... we forgot the CLient registry key that tells Outlook to use the Server Security settings as documented here ...

http://www.slipstick.com/outlook/esecup/admin.htm

Steve
0
 
LVL 39

Author Comment

by:stevbe
ID: 12299577
hey ee ... is  THX 1138 your cousin?
0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Sometimes Outlook might have problems sending a message. There may be various causes- corrupted PST, AV scanner etc. The message, instead of going to the Sent Items folder, sits in the Outbox indefinitely. To remove it you can use a free tool cal…
If you don't know how to downgrade, my instructions below should be helpful.
To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
CodeTwo Sync for iCloud (http://www.codetwo.com/sync-for-icloud?sts=6554) automatically synchronizes your Outlook 2016, 2013, 2010 or 2007 folders with iCloud folders available via iCloud Control Panel. This lets you automatically sync them with…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now