jerome313131
XLDnaute Nouveau
Bonjour quand je lance ma macro j'ai une erreur code erreur d’exécution 13 incompatible de type
Pouvez vous m'aider merci
Sub relance()
Dim C As Range, olApp As Object, M As Object
Set olApp = CreateObject("Outlook.application")
For Each C In Range("A2", Cells(Rows.Count, 1).End(xlUp))
If IsDate(C.Offset(, 1)) And Date - C.Offset(, 1) > 5 Then
If C.Offset(, 1).Interior.ColorIndex = 6 Then
Set M = olApp.CreateItem(olMailItem)
With M
.Subject = "RELANCE commande " + C.Offset(, 4).Value
.Recipients.Add C.Offset(, 3).Value
.Body = " Bonjour, pouvez vous nous donner le délais de livraison concernant notre commande citée en objet . Cordialement Climax-sav Mr Charrier J."
.Display
End With
End If
End If
Next C
End Sub
Pouvez vous m'aider merci
Sub relance()
Dim C As Range, olApp As Object, M As Object
Set olApp = CreateObject("Outlook.application")
For Each C In Range("A2", Cells(Rows.Count, 1).End(xlUp))
If IsDate(C.Offset(, 1)) And Date - C.Offset(, 1) > 5 Then
If C.Offset(, 1).Interior.ColorIndex = 6 Then
Set M = olApp.CreateItem(olMailItem)
With M
.Subject = "RELANCE commande " + C.Offset(, 4).Value
.Recipients.Add C.Offset(, 3).Value
.Body = " Bonjour, pouvez vous nous donner le délais de livraison concernant notre commande citée en objet . Cordialement Climax-sav Mr Charrier J."
.Display
End With
End If
End If
Next C
End Sub