Directory List

Posted on 1998-07-15
Last Modified: 2012-05-05
   I am creating a web page that is currently being saved as an asp file.  One of the tasks I need to do is create a list of text files in a document on my network then list them on a page with a hyperlink enabling the client to read the text file when clicking the hyperlink on the list.  Can someone please help?  If you need some more information please let me know.
Question by:TrEaSoN
  • 3
  • 2

Accepted Solution

BlackMan earned 200 total points
ID: 1844636
You can use FileSystemObject. Here is an example using VBScript:

Set fs = CreateObject("Scripting.FileSystemObject")
Set f = fs.GetFolder("C:\winnt")
Set fc = f.Files
For Each f1 in fc
Response.write & "<br>"

FileSystemObject doesn't come with IIS, it comes with Windows Scripting Host. Surf to and install WSH. You must install it on the IIS server


Author Comment

ID: 1844637
Do I put this code inside of the <head> tag?

Author Comment

ID: 1844638
Never Mind, I got it to work.  But I still need to know how to put file size and date created next to it.  If you can tell me that, the points are yours.

Expert Comment

ID: 1844639
I think it is F1.Size and F1.Date, but it is in the WSH documentation...

Author Comment

ID: 1844640

  I tried that, but it didn't work.  It doesn't matter though because I did what i needed to do.  Thanks for the help.

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

SASS allows you to treat your CSS code in a more OOP way. Let's have a look on how you can structure your code in order for it to be easily maintained and reused.
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now