Read the docs for .Run completely and reflect on the bWaitOnReturn
parameter.
Apology:
Sorry, I didn't read your code carefully enough. The .Run should wait. But I see that you use a global On Error Resume Next
and param list () in
WshShell.run ("cmd /K " & "copy /Y " & path & FICRIEC & sessio & "+" & FileName & " " & path & FICRIEC & sessio & "_tmp",8,TRUE)
What happens, when you remove those mistakes? Are you sure, that you have a usable WshShell
in the second pass thru the loop?