![]() |
add appointment to additional calander?
Hi
I have found the code to open the calander from an attached mailbox. I cant work out how to create a new appointment. The options i end up with allow to display the additional calander and no reference to create an appointment. Is this possible? Im also using similiar code to open a new message from an additional mailbox and run into the same problem. my stuff so far: Dim myOlApp As Outlook.Application Dim myNamespace As Outlook.NameSpace Dim myRecipient As Outlook.Recipient Dim CalendarFolder As Outlook.MAPIFolder Set myOlApp = CreateObject("Outlook.Application") Set myNamespace = myOlApp.GetNamespace("MAPI") Set myRecipient = myNamespace.CreateRecipient("IT") 'open additional calendar myRecipient.Resolve Set CalendarFolder = myNamespace.GetSharedDefaultFolder _ (myRecipient, olFolderCalendar) CalendarFolder.Display 'opens the IT Calendar..find a way to add appointment? With thanks |
add appointment to additional calander?
If you have write permissions on that folder, this will work. Just set a
reference to the CalendarFolder.Items object, and call the Add method from it using olAppointmentItem as the argument. -- Eric Legault (Outlook MVP, MCDBA, old school WOSA MCSD, B.A.) Try Picture Attachments Wizard for Outlook: http://www.collaborativeinnovations.ca Blog: http://blogs.officezealot.com/legault/ "Sydney" wrote: Hi I have found the code to open the calander from an attached mailbox. I cant work out how to create a new appointment. The options i end up with allow to display the additional calander and no reference to create an appointment. Is this possible? Im also using similiar code to open a new message from an additional mailbox and run into the same problem. my stuff so far: Dim myOlApp As Outlook.Application Dim myNamespace As Outlook.NameSpace Dim myRecipient As Outlook.Recipient Dim CalendarFolder As Outlook.MAPIFolder Set myOlApp = CreateObject("Outlook.Application") Set myNamespace = myOlApp.GetNamespace("MAPI") Set myRecipient = myNamespace.CreateRecipient("IT") 'open additional calendar myRecipient.Resolve Set CalendarFolder = myNamespace.GetSharedDefaultFolder _ (myRecipient, olFolderCalendar) CalendarFolder.Display 'opens the IT Calendar..find a way to add appointment? With thanks |
add appointment to additional calander?
Got it thanks!
I also needed to declare a variable as Outlook.AppointmentItem. Perhaps i could have worked without that but hey...its working :) "Eric Legault [MVP - Outlook]" wrote in message ... If you have write permissions on that folder, this will work. Just set a reference to the CalendarFolder.Items object, and call the Add method from it using olAppointmentItem as the argument. -- Eric Legault (Outlook MVP, MCDBA, old school WOSA MCSD, B.A.) Try Picture Attachments Wizard for Outlook: http://www.collaborativeinnovations.ca Blog: http://blogs.officezealot.com/legault/ "Sydney" wrote: Hi I have found the code to open the calander from an attached mailbox. I cant work out how to create a new appointment. The options i end up with allow to display the additional calander and no reference to create an appointment. Is this possible? Im also using similiar code to open a new message from an additional mailbox and run into the same problem. my stuff so far: Dim myOlApp As Outlook.Application Dim myNamespace As Outlook.NameSpace Dim myRecipient As Outlook.Recipient Dim CalendarFolder As Outlook.MAPIFolder Set myOlApp = CreateObject("Outlook.Application") Set myNamespace = myOlApp.GetNamespace("MAPI") Set myRecipient = myNamespace.CreateRecipient("IT") 'open additional calendar myRecipient.Resolve Set CalendarFolder = myNamespace.GetSharedDefaultFolder _ (myRecipient, olFolderCalendar) CalendarFolder.Display 'opens the IT Calendar..find a way to add appointment? With thanks |
All times are GMT +1. The time now is 06:44 AM. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2006 OutlookBanter.com