Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 49
Default Excel to add event on outlook calender

Is there a way to get excel to add an event onto an outlook calender?

My spreadsheet is set up to have a few possible fields, but i want when
'Annual Leave' is selected, an outlook calender all day event to be added.

Excel and outlook will be open at the same time so nothing needs opening.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 49
Default Excel to add event on outlook calender

I have the macro now to add the event onto my calender.

Sub Add_Appointment()
Dim myOlapp As Object
Dim myitem As Object

Set myOlapp = CreateObject("Outlook.Application")
Set myitem = myOlapp.createitem(1)

With myitem
.Body = "Annual Leave."
'.Duration = dur'
.AllDayEvent = True
.Subject = "A/L"
.Save

End With

Set myitem = Nothing
Set myOlapp = Nothing

End Sub

What i now would like to know is:-

1) A code to run this macro if a field is changed, for example if a cell
between range b1 to b14 changes to A/L i want this to run and add the
appointment into my calender. This could also be done by clicking a button
after any updates have been made.

2) What field do i need to change to select the calender i want this added
to, i can get this to add to my calender, but eventually want it to add to a
shared calender.

3) Is there a way to only add new appointments, and not repeating the old
ones.

Thanks in advance
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Create Outlook Calendar event from dates in excel Betty Excel Discussion (Misc queries) 0 October 15th 09 04:12 PM
Create Outlook Calendar event from date in Excel kimbo Excel Discussion (Misc queries) 0 July 31st 09 01:46 PM
Outlook Calender Duration Conversion in Excel MarkMcG Excel Worksheet Functions 0 September 29th 08 03:26 PM
Outlook Calender to Excel Spreadsheet Jason Excel Worksheet Functions 1 January 31st 06 12:11 AM
How do I copy a date from excel to a outlook calender? Pip Excel Discussion (Misc queries) 0 August 5th 05 01:00 PM


All times are GMT +1. The time now is 01:20 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"