![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#3
|
|||
|
|||
![]()
Hi,
This is a folder with notes. For some unknown reasons, it contains several objects and files inside but "is NOT" a outlook folder. I got workaround, I added the calendar to everyone's Favorites folder and access it from there instead. Thanks AD "Michael Bauer [MVP - Outlook]" wrote: It seems that the folder '*Education Calendar' doesn't exist. Are you sure the folder name really starts with '*'? -- Viele Gruesse / Best regards Michael Bauer - MVP Outlook Quick-Cats - The most effective way to assign Outlook categories: http://www.shareit.com/product.html?...4&languageid=1 (German: http://www.VBOffice.net/product.html?pub=6) Am Thu, 15 Mar 2007 21:48:00 -0700 schrieb AirDuster101: Hi, I am using outlook2003 and Exchange Server. I am trying to locate a calendar name "*Education Calendar" in a public folder. The path is "Public Folders\All Public Folders\EDUCATION\*Education Calendar". I've found the below script on Sue Mosher's site, but it can never find the subfolder "EDUCATION". The object always returns "Nothing"... I don't know why? Please help! I also tried in mixed case "Education". Same error. Thanks ================================================== =========== Dim objFolder As Outlook.MAPIFolder Set objFolder = GetFolder("Public Folders/All Public Folders/Education/*Education Calendar") Public Function GetFolder(strFolderPath As String)As MAPIFolder ' folder path needs to be something like ' "Public Folders\All Public Folders\Company\Sales" Dim objApp As Outlook.Application Dim objNS As Outlook.NameSpace Dim colFolders As Outlook.Folders Dim objFolder As Outlook.MAPIFolder Dim arrFolders() As String Dim I As Long On Error Resume Next strFolderPath = Replace(strFolderPath, "/", "\") arrFolders() = Split(strFolderPath, "\") Set objApp = CreateObject("Outlook.Application") Set objNS = objApp.GetNamespace("MAPI") Set objFolder = objNS.Folders.Item(arrFolders(0)) If Not objFolder Is Nothing Then For I = 1 To UBound(arrFolders) Set colFolders = objFolder.Folders Set objFolder = Nothing Set objFolder = colFolders.Item(arrFolders(I)) If objFolder Is Nothing Then Exit For End If Next End If Set GetFolder = objFolder Set colFolders = Nothing Set objNS = Nothing Set objApp = Nothing End Function Isabelle |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
operation failed and object could not be found | Sabu | Outlook - Calandaring | 0 | September 10th 06 11:18 PM |
The operation failed. An object could not be found. | [email protected] | Outlook and VBA | 3 | February 16th 06 01:16 AM |
Operation Failed. An object could not be found | Raymon | Outlook - Installation | 0 | January 21st 06 03:26 AM |
operation failed - object could not be found | Lynne | Outlook - Installation | 1 | January 20th 06 04:01 PM |
the operation failed. the object could not be found. | ChandleyCrawford | Outlook - Installation | 0 | January 12th 06 10:05 PM |