![]() |
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 |
#1
|
|||
|
|||
![]()
Hi all.
I am stuck. In my enviroment we have a public calendar with heaps of professional events. i am trying to create a VBA code linked to a button that once pressed it would add the user that pressed it to the list of required attendees to the existing event. Can any one help me Thank you Andrew |
Ads |
#2
|
|||
|
|||
![]()
Get the calendar appointment from
Application.ActiveExplorer.Selection.Item(1). Get its Recipients collection, get NameSpace.CurrentUser.Address. Add that to the Recipients collection using the Recipients.Add method. Specify the Recipient.Type as olTo, which means required recipient. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007. Reminder Manager, Extended Reminders, Attachment Options. http://www.slovaktech.com/products.htm "Andrew" wrote in message ... Hi all. I am stuck. In my enviroment we have a public calendar with heaps of professional events. i am trying to create a VBA code linked to a button that once pressed it would add the user that pressed it to the list of required attendees to the existing event. Can any one help me Thank you Andrew |
#3
|
|||
|
|||
![]()
Hi Ken
Unfortuanly i am very limited in my understanding of the VBA Scripting could you please show me te example of what you mean. Thank you for your time Andrew "Ken Slovak - [MVP - Outlook]" wrote: Get the calendar appointment from Application.ActiveExplorer.Selection.Item(1). Get its Recipients collection, get NameSpace.CurrentUser.Address. Add that to the Recipients collection using the Recipients.Add method. Specify the Recipient.Type as olTo, which means required recipient. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007. Reminder Manager, Extended Reminders, Attachment Options. http://www.slovaktech.com/products.htm "Andrew" wrote in message ... Hi all. I am stuck. In my enviroment we have a public calendar with heaps of professional events. i am trying to create a VBA code linked to a button that once pressed it would add the user that pressed it to the list of required attendees to the existing event. Can any one help me Thank you Andrew |
#4
|
|||
|
|||
![]()
There's no error handling in this and it's just a basic example that assumes
that whatever is selected is actually an appointment item. The code also assumes it's running in the Outlook VBA project. Sub AddRecip() Dim oAppt As Outlook.AppointmentItem Dim colRecips as Outlook.Recipients Dim oRecip As Outlook.Recipient Set oAppt = Application.ActiveExplorer.Selection.Item(1) Set colRecips = oAppt.Recipients Set oRecip = colRecips.Add(Application.Session.CurrentUser.Addr ess) oRecip.Type = olTo oAppt.Save Set oRecip = Nothing Set colRecips = Nothing Set oAppt = Nothing End Sub -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007. Reminder Manager, Extended Reminders, Attachment Options. http://www.slovaktech.com/products.htm "Andrew" wrote in message ... Hi Ken Unfortuanly i am very limited in my understanding of the VBA Scripting could you please show me te example of what you mean. Thank you for your time Andrew |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
How delete appointment without scan app the existing appointment | Yanshof | Outlook - Calandaring | 1 | March 2nd 09 03:04 PM |
Unable to add others to existing appointment | Christine | Outlook - Calandaring | 0 | January 16th 09 12:49 AM |
delete or change existing appointment | khowes | Outlook - Calandaring | 1 | November 21st 08 04:46 PM |
When i open an existing appointment in Outlook Calendar, then close, it automatically creates an unwanted recurring appointment. | David H | Outlook - Calandaring | 1 | June 28th 07 10:32 AM |
Resending Existing Appointment bu to only 1 invitee | Danielle | Outlook - Calandaring | 2 | April 4th 07 10:08 PM |