R
Ryan Hubbard
I used the following code given to be me from Ken.
It works fine on one computer using Outlook 2003 No Exchange. I tried
using it on another computer with Outlook 2003 with Exchange and I get
the following error: [Collaberation Data Objects -
[E_ACCESSDENIED(80070005)]]
Any reason why? And how do I solve it. Thanks
Const CdoPR_FINDER_ENTRYID = &H35E70102
Dim objSession As New MAPI.Session
Dim objInfostore As MAPI.InfoStore
Dim objFinderFolder As MAPI.Folder
Dim objRootFolder As MAPI.Folder
Dim objFolders As MAPI.Folders
Dim objFolder As MAPI.Folder
Dim strFinderEntryID As String
objSession.Logon "", "", False, False
Set objInfostore = objSession.GetInfoStore(objSession.Inbox.StoreID)
strFinderEntryID =
objInfostore.Fields.Item(CdoPR_FINDER_ENTRYID).Value
Set objFinderFolder = objSession.GetFolder(strFinderEntryID,
objInfostore.ID)
Set objRootFolder = objSession.GetFolder(objFinderFolder.FolderID,
objInfostore.ID)
Set objFolders = objRootFolder.Folders
Set objFolder = objFolders.Add("Foobar")
It works fine on one computer using Outlook 2003 No Exchange. I tried
using it on another computer with Outlook 2003 with Exchange and I get
the following error: [Collaberation Data Objects -
[E_ACCESSDENIED(80070005)]]
Any reason why? And how do I solve it. Thanks
Const CdoPR_FINDER_ENTRYID = &H35E70102
Dim objSession As New MAPI.Session
Dim objInfostore As MAPI.InfoStore
Dim objFinderFolder As MAPI.Folder
Dim objRootFolder As MAPI.Folder
Dim objFolders As MAPI.Folders
Dim objFolder As MAPI.Folder
Dim strFinderEntryID As String
objSession.Logon "", "", False, False
Set objInfostore = objSession.GetInfoStore(objSession.Inbox.StoreID)
strFinderEntryID =
objInfostore.Fields.Item(CdoPR_FINDER_ENTRYID).Value
Set objFinderFolder = objSession.GetFolder(strFinderEntryID,
objInfostore.ID)
Set objRootFolder = objSession.GetFolder(objFinderFolder.FolderID,
objInfostore.ID)
Set objFolders = objRootFolder.Folders
Set objFolder = objFolders.Add("Foobar")