Am I going mad? I cannot find a way to get hold of the first file in a folder with the FileSystemObject (classic ASP). With most collections you'd think the index 0 or 1 might work, but IIS says "Invalid procedure call or argument".
Neither of these last 2 lines work:
Set oFileScripting = CreateObject("Scripting.FileSystemObject")
Set oFolder = oFileScripting.GetFolder(sFolder)
Set oFiles = oFolder.Files
If oFiles.Count = 0 Then Response.Write "no files"
Response.Write oFiles(0).Name
Response.Write oFiles.Item(1).Name
Am I being mega-stupid, or is there no way to use an index to access this particular collection?