469,133 Members | 1,015 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,133 developers. It's quick & easy.

question on FileSystemObject

1
I'm trying to get a list of file names from a folder into an array and use them as links in my script. I'm new to VBScript and I can't seem to be able to get at the file names... any suggestions? here's the code

Dim FSO
Set FSO = Server.CreateObject("Scripting.FileSystemObject")
Dim Folder
dir = Server.MapPath("./Slides")
Set Folder = FSO.GetFolder(dir)
Dim File
For Each File in Folder.Files

Slides(i) = File
i = i+1
Response.Write Slides(i).name&"<br>"

Next


is there some kind of cast i have to do? I'm totally lost guys
Apr 27 '06 #1
0 1289

Post your reply

Sign in to post your reply or Sign up for a free account.

By using this site, you agree to our Privacy Policy and Terms of Use.