Wie kann ich via VBA Termine im Outlook suchen und löschen?
Mit diesem Code kann ich immer nur alle Daten aus dem Outlook auslesen. Ich möchte jedoch nur die Einträge, welche "BWL" beinhalten haben. Wer kann mir helfen?
Sub suchen_Outlook()
Set myOlApp = CreateObject("Outlook.Application")
Set myNameSpace = myOlApp.GetNamespace("MAPI")
tdystart = "19.06.2003 12:00"
tdyend = "21.06.2003 12:00"
Set myAppointments = myNameSpace.GetDefaultFolder _
(olFolderCalendar).Items
Set currentAppointment = myAppointments.Find("[Start] >= ""BWL" & _
tdystart & """ and [Start] <= ""BWL" & tdyend & """")
While TypeName(currentAppointment) <> "Nothing"
MsgBox currentAppointment.Subject
Set currentAppointment = myAppointments.FindNext
Wend
End Sub
Besten Dank
Gruss Markus