Les mémos
Je débute...
Visites

 988008 visiteurs

 1 visiteur en ligne

Recherche
 
Fermer

Lire les rendez-vous dans le calendrier Outlook

Sub LireRDV()
    Dim Ol_App As New Outlook.Application
    Dim Ol_Mapi As Outlook.NameSpace
    Dim Ol_Folder As Outlook.MAPIFolder
    Dim Ol_Items As Outlook.Items
    Dim Ol_Appointment As Outlook.AppointmentItem

    Set Ol_Mapi = Ol_App.GetNamespace("MAPI")
    Set Ol_Folder = Ol_Mapi.GetDefaultFolder(olFolderCalendar)
    Set Ol_Items = Ol_Folder.Items

    For Each Ol_Appointment In Ol_Items
        With Ol_Appointment
            MsgBox "Rendez-Vous : " & .Subject & vbCrLf _
                   & "Début : " & .Start & vbCrLf _
                   & "Fin : " & .End & vbCrLf _
                   & "Convoqués : " & .RequiredAttendees & vbCrLf _
                   & "Invités : " & .OptionalAttendees & vbCrLf _
                   & "Lieu : " & .Location
        End With
    Next Ol_Appointment

    Set Ol_Appointment = Nothing
    Set Ol_Items = Nothing
    Set Ol_Folder = Nothing
    Set Ol_Mapi = Nothing
    Set Ol_App = Nothing
End Sub


Catégorie : Les mémos - Outlook
Page lue 5736 fois