The Scripting.FileSystemObject is much more robust that the legacy methods in this topic. It should be preferred in almost all cases.
Scripting.FileSystemObject