Guest oralfa Posted February 20, 2006 Share Posted February 20, 2006 Hi to everyone!Can anybody help me? I am looking for an ASP function, that gives me the list of names of all files in any folder on the server. Does that function exist? Link to comment Share on other sites More sharing options...
Pollux Posted February 21, 2006 Share Posted February 21, 2006 Try this: <% ' Retrieve directory from filesystem. Set FS = Server.CreateObject("Scripting.FileSystemObject") Set Dir = FS.GetFolder(Server.MapPath("/foldername")) ' Write out the name of each file in directory. For each fileItem in Dir.files Response.Write(fileItem.Name) Next%> Link to comment Share on other sites More sharing options...
netcracker Posted February 21, 2006 Share Posted February 21, 2006 Hi to everyone!Can anybody help me? I am looking for an ASP function, that gives me the list of names of all files in any folder on the server. Does that function exist?First of all you will not be able to see anything unles directory browsing is enabled. If it is so, why bodder whith a script when IE or WinExplorer can do the job.But I have the feeling that you are trying to do some hacking, and steal somthing from somewhere...You could have used google instead of posting here, it might have been faster ! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now