Sub envoi_Feuille_par_email()
' Avant de lancer cette macro : Dans l'éditeur VBA, faire
' Menu / Outils / Références... /
' et cocher "Microsoft Outlook 11.0 Object Library"
If MsgBox("Êtes vous sur de vouloir envoyer le compte rendu journalier par email ?", vbQuestion + vbYesNo, "Quelle classe le BEAUF ...") = vbYes Then
Dim répertoireAppli As String, olapp As New Outlook.Application, msg As MailItem, s As String
    Application.ScreenUpdating = False
    répertoireAppli = ActiveWorkbook.Path
    Sheets("Lundi").Copy
    Application.DisplayAlerts = False
    ActiveWorkbook.SaveAs répertoireAppli & "\CR journalier email.xls"
    Application.DisplayAlerts = True
    ActiveWindow.Close
    Application.ScreenUpdating = True
    Sheets("Destinataires").Activate
    Range("A11").Select
    Do While Not IsEmpty(ActiveCell)
        s = s & ActiveCell.Value & "; "
        ActiveCell.Offset(1, 0).Select
    Loop
    s = Left$(s, Len(s) - 2)
    Set msg = olapp.CreateItem(olMailItem) ' Envoi par mail
    msg.To = s
    msg.Subject = Range("A2").Value
    msg.Body = Range("A5").Value & Chr(13) & Chr(13) & Range("A8").Value & Chr(13) & Chr(13)
    msg.Attachments.Add répertoireAppli & "\Plongée du jour.xls"
    msg.Send
    UserForm2.Hide
    
End If
End Sub
Sub lit_messagerie()
  Dim olapp As Outlook.Application   'penser à Outils/Références Outlook
  Dim olns As Outlook.NameSpace
  Dim olmf As Outlook.MAPIFolder
  Dim obj As Object
  Set olapp = New Outlook.Application
  Set olns = olapp.GetNamespace("mapi")
  Set olmf = olns.GetDefaultFolder(olFolderInbox)
  For Each obj In olmf.Items
   MsgBox obj.Subject
  Next
End Sub