If Application.Wait(Now + TimeValue("00:01:00")) Then
Range("A1").Select
Selection.ClearContents
End If
Dim lgn&
lgn = Range("A" & Rows.Count).End(xlUp).Row
For i = 2 To lgn
If Cells(i, 7) = CDate(Format(Now, "dd/mm/yyyy")) Then
Cells(i, 5) = ""
Cells(i, 6) = ""
Cells(i, 7) = ""
End If
Next i
Call UserForm_Initialize
Sub annuler()
Dim lgn&
lgn = Range("A" & Rows.Count).End(xlUp).Row
With ThisWorkbook.Worksheets("Feuil1")
For i = 2 To lgn
If .Cells(i, 7) <> "" Then
If .Cells(i, 7) <= CDate(Format(Now, "dd/mm/yyyy")) Then
.Cells(i, 5) = ""
.Cells(i, 6) = ""
.Cells(i, 7) = ""
End If
End If
Next i
End With
UserForm1.int1
Call test
End Sub
Sub test()
Application.OnTime Now + TimeValue("00:05:00"), "annuler"
End Sub
Vous avez trouvé cette solution
Merci le forum