-
Dec 13th, 2002, 03:24 AM
#1
*RESOLVED* CDO 1.21 problems after security update
A client asked for word templates, which use the exchange server's global address list to get address information.
The method that used to work, doesn't work anymore when the CDO security patch is installed.
The configuration is:
Outlook 2000
Word 97
Exchange server (5.5?)
I am using the AddressBook method of CDO's session object.
According to Microsofts documentation, a dialog box should appear, asking the user to allow access to the address list.
This dialog box does not appear, instead a runtime error occurs as soon as I try to read the selected recipient.
The error is E_ACCESSDENIED(80070005)
Why doesn't the dialog box appear, and is access blocked?
Should I tell my client that the job can't be done?
Here is the sample code I used:
VB Code:
Private Sub CommandButton1_Click()
Dim ses As MAPI.Session
Dim recs As MAPI.Recipients
Dim rec As MAPI.Recipient
Set ses = New MAPI.Session
ses.Logon "MS Exchange Settings"
Set recs = ses.AddressBook(, "Selecteer een ontvanger", 1, 1, 1)
Set rec = recs.Item(1) ' this is where i get the error
Me.txtAchternaam.Text = rec.Name
Set rec = Nothing
Set recs = Nothing
ses.Logoff
Set ses = Nothing
End Sub
Any information is appreciated.
I am also open for alternative methods to read the exchange server's global address list, but I need to be able to access several exchange specific fields in the addressentry, so using the Outlook object model is not an option.
Last edited by Frans C; Dec 13th, 2002 at 09:26 AM.
-
Dec 13th, 2002, 11:22 AM
#2
Frenzied Member
We would be interested in what you had to do to get this working....
Was it an error in the CDO update? or where?
-
Dec 13th, 2002, 01:03 PM
#3
I removed outlook, and reinstalled it.
I think I know what the problem was, but I am not sure.
Because I need to develop with VB and MS office, and can have customers with different versions of Office, both Office97 and Office 2000 is installed on my machine.
Unfortunately, the admin installed them in the wrong order.
He first installed Office 2000, and then Office 97.
If you ever need both versions on the same machine, I advise you to install them in the order they appeared, so first office 97 and then Office 2000 (or later).
This is already problem number 4 or so, that was caused by the wrong order of installations.
After reinstalling Outlook the expected behaviour was back; outlook came with a question if I wanted to allow the other program to access my address list. This is acceptable to me.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|