View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Memphis Memphis is offline
external usenet poster
 
Posts: 32
Default Launching Outlook Calendar

You are the "Man"!
This is exactly what i was looking for.

Thank you so much.


"Office_Novice" wrote:

Maybe somthing like this is more acceptable =o)

Option Explicit

Public Sub NewOutlookAppointment()
Dim Outlook As Object
Dim Appointment As Object

Set Outlook = CreateObject("Outlook.Application")


Set Appointment = Outlook.CreateItem(1)

Appointment.Display
End Sub


"Memphis" wrote:

This is definitely more than I asked for. Thank you so much.

I am using Office 2003. I copied your first code and after running it I get
a "Type mismatch (Error 13)"
I do not know what to make of it. I will try to work out the error later,
unless you can shed some light on this.

For the time being, how can I launch Outlook and automatically have it pop
up a new blank appointment on the screen for me to manually fill out with the
subject, date and time?

Thank you

"Office_Novice" wrote:

Try this

Public Sub MakeOutlookAppointment()
Dim Outlook As Object
Dim Appointment As Object
Const Item = 1

Set Outlook = CreateObject("Outlook.Application")
Set Appointment = Outlook.CreateItem(Item)

Appointment.Subject = Range("A2").Value
Appointment.Start = Format(Range("B2").Value, "hh:mm AMPM") + _
Format(Range("C2").Value, "mm/dd/yyyy")

Appointment.End = Format(Range("D2").Value, "hh:mm AMPM") + _
Format(Range("E2").Value, "mm/dd/yyyy")

Appointment.ReminderPlaySound = True
Appointment.Save

Outlook.Quit
Set Outlook = Nothing
End Sub



"Memphis" wrote:

Hello,
I case control sheet in Excel, I need to follow-up on cases I work on so I
use Outlook to create follow-up reminders after I mail out documents to
individuals.
I run Outlook in the background all the time.
I figured how to add a cmd button to excel to launch Outlook
(Application.ActivateMicrosoftApp xlMicrosoftMail). I would like to take it a
step farther and be able to Launch Outlook and display a new blank
appointment for todays date so that I may create a new appointment and add a
reminder.

Thank you.