Add an event / meeting in Outlook via Excel ?

  • Thread starter Thread starter Mark Rosenkrantz
  • Start date Start date
M

Mark Rosenkrantz

Dear all;

I want to add an event in Outlook by clicking a commandbutton on a UserForm.
I don't know if this is possible, but as many thnings can be done by VBA I
thought that one of you goeroes
might have a solution to this.

Can this be done ?

Mark.
 
Mark,

Here is a simple example

Sub CreateOutlookAppointment()
Dim oItem As Object
Dim oOLApp As Object
Set oOLApp = CreateObject("Outlook.Application")
Set oItem = oOLApp.CreateItem(1) 'olAppointmentItem
With oItem
.Subject = "Test value"
.Location = "My house"
.Start = #7/27/2004 10:00:00 AM#
.Duration = 30 ' minutes
.Body = "The agenda is as follows"
.Save
End With
End Sub


--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top