-
I need to create several random files
Creation date of these files should be different by milliseconds. I have tried to put a delay between the file's creation but it either does not work (the same milliseconds) or it rounds up to a second. The code I tried:
[vba] For y = 1 To intNFiles
Set objFSO = New FileSystemObject
Set objFSOFile = objFSO.CreateTextFile(strSourceFolder & "Test" & y & ".txt", False)
Sleep 95&
Set objFSO = Nothing
Set objFSOFile = Nothing
Next[/vba]
As an option it should be possible to reset creation date with API SetFileTime but that is the last option I would use. Any ideas how to fix it?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules