Attendre que le fichier existe

Const timeoutSeconds As Long = 128

Public Function https://stackoverflow.com/questions/37065764/how-to-check-until-file-exist(ByVal theFileName As String) As Boolean
    Dim startTime As Single
    startTime = Timer
    
    Do
        If FSO.FileExists(theFileName) Then
            WaitForFileToExist = True
            Exit Do
        End If

        DoEvents
        Application.Wait Now + TimeValue("0:00:01")
        
        timeElapsed = Timer - startTime
    Loop Until timeElapsed > timeoutSeconds 
End Function
Thankful Tamarin