View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
bigproblem bigproblem is offline
external usenet poster
 
Posts: 17
Default copy the command button and macro for multiple rows

How can I copy the command button and macro for multiple rows ?

Private Sub CommandButton1_Click()
Dim Outlook As Object
Dim Appointment As Object
Dim Category As String
Dim Time As Variant

Const Item = 1

Set Outlook = CreateObject("Outlook.Application")
Set Appointment = Outlook.CreateItem(1)
Time = "08:30AM"

Appointment.Location = Range("a2") & ", " & Range("d2") & ", " & Range("e2")

Appointment.Subject = Range("i2")

Appointment.Start = DateAdd("d", 350, Range("b2")) & " " & Time

Appointment.Body = Range("a2") & ", " & Range("b2") & ", " & Range("c2") &
", " & Range("d2") & ", " & Range("e2")



Appointment.ReminderPlaySound = True
Appointment.Display

'Outlook.quit
'Set Outlook = Nothing
End Sub
--
problem