PC Review


Reply
Thread Tools Rate Thread

Copying Excel schedules to different Outlook Calendars

 
 
littlegreenmen1
Guest
Posts: n/a
 
      1st Jul 2005

I am a contractor and have a schedule in Excel for each of the house
I'm building. As it is right now, I have a macro that exports all th
relevant information from each of my schedules (one at a time) an
imports it into Outlook. This works just fine. My problem is, I have s
much information on one calendar that it makes it hard to read. I hav
setup Outlook Calendar to have a different calendar for each job. Ho
do I get Excel to send the schedule to it's approriate Calendar (ie
the Excel schedule for 123 Anywhere St would be copied to the Outloo
Calendar for 123 Anywhere St and not the default calendar). Below is m
existing code that will export everything into just the defaul
calendar. Thank you for any and all help.

Sub Calendar()
Dim olApp As Object
Dim olApt As Object
Dim x As Integer
Dim olBody As Range
Dim olSubject As Range
Dim olDate As Range
Dim olAddress As Range

EraseCalendar

For x = 3 To 200
Set olSubject = Sheet1.Cells.Item(x, "B")
Set olNotes = Sheet1.Cells.Item(x, "J")
Set olDate = Sheet1.Cells.Item(x, "C")
Set olAddress = Sheet1.Cells.Item(1, "O")
Set olApp = CreateObject("Outlook.application")
Set olApt = olApp.CreateItem(1)

If olDate = "" Then
Exit For
End If

If olSubject = "Start Date" Then
GoTo Label1
End If

If olDate = "Date Required" Then
GoTo Label1
End If

If olDate < Date Then
GoTo Label1
End If

With olApt
.AllDayEvent = True
.Start = olDate
.Subject = olSubject
.Location = olAddress
.Categories = olAddress
.Body = olNotes
.BusyStatus = 0
.ReminderSet = False
.Save
End With

Set olApp = Nothing
Set olApt = Nothing

Label1:
Next x

End Su

--
littlegreenmen
-----------------------------------------------------------------------
littlegreenmen1's Profile: http://www.excelforum.com/member.php...fo&userid=2397
View this thread: http://www.excelforum.com/showthread.php?threadid=38398

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Import free Big10 Schedules into Outlook and other calendars asnicholasjr@comcast.net Windows XP General 0 12th Aug 2006 04:44 AM
Import free Big10 Schedules into Outlook and other calendars asnicholasjr@comcast.net Microsoft Outlook Calendar 0 12th Aug 2006 04:41 AM
Import free Big10 Schedules into Outlook and other calendars asnicholasjr@comcast.net Microsoft Outlook 0 12th Aug 2006 02:59 AM
Import free Big10 Schedules into Outlook and other calendars asnicholasjr@comcast.net Microsoft Outlook Discussion 0 12th Aug 2006 02:59 AM
Calendars and Schedules Martin Hazell Microsoft C# .NET 1 8th Aug 2003 11:35 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:21 AM.