How to access item in collection? Next code gives me error in last line.
**
The .Files collection can't be accessed by index:
>> Set oFiles = goFS.GetFolder(".\").Files
>> n = oFiles(0).Name
>>
Error Number: 5
Error Description: Invalid procedure call or argument
You need a For Each loop to fill a random access collection e.g. an Array:
>> Set oFiles = goFS.GetFolder(".\").Files
>> ReDim aFiles(oFiles.Count - 1)
>> i = 0
>> For Each oFile In oFiles
>> Set aFiles(i) = oFile
>> Next
>> n = aFiles(0).Name
>> WScript.Echo n
>>
31823568.notes