Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi all! We have been experiencing an issue on site where threads have been missing the latest postings. The platform host Vanilla are working on this issue. A workaround that has been used by some is to navigate back from 1 to 10+ pages to re-sync the thread and this will then show the latest posts. Thanks, Mike.
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Printing a directory's contents to .txt file

  • 20-03-2009 12:42pm
    #1
    Closed Accounts Posts: 37


    Hi All,

    I'm in work at the moment and have been asked to list out a directory in a certain format. Fine says I. But then I check there's over 4000 files in the directory. I'm looking for a freeware program that will list the contents in text file so I can just copy paste into the database. I've downloaded a freeware program called "Karen's Directory Printer"... It's exactly what I need but when I try and access the directory I want I can't find it any where on the network drive. It will only display the first 8 or so network directories, so its kinda useless to me.

    I was just gonna copy the directory onto my harddrive and do it from there - but its over 16gigs worth of stuff, I'll be waiting for days trying to get it on here.

    Has anyone any suggestions how I can do this?


Comments

  • Registered Users, Registered Users 2 Posts: 11,987 ✭✭✭✭zAbbo


    Open command prompt (start > run > cmd)
    dir C:\directory > C:\dir.txt
    

    replace c:\diretory with the location of the folder, this prints the contents into a text file (c:\dir.txt)

    You can play around with various dir switches (dir /?) to get the format which suits.

    Some links
    http://www.easydos.com/dir.html
    http://www.computerhope.com/dirhlp.htm
    http://www.ahuka.com/dos/lesson12.html
    http://www.chami.com/tips/windows/110996W.html
    http://articles.techrepublic.com.com/5100-10878_11-5035179.html


  • Closed Accounts Posts: 37 damp sponge


    Thanks man, Got it working. Now its just the small matter of copying and pasting each entry into the database, still must have saved myself a good few hours of trawling through each folder etc...


    Thanks again.


  • Registered Users, Registered Users 2 Posts: 11,987 ✭✭✭✭zAbbo


    what kind of database? surely you can populate it with a script?


  • Closed Accounts Posts: 37 damp sponge


    Its to go into an excel file so we can check what files we have against another companies file list. They keep these files arranged in different fodlers, whereas I set ours up differently. I'm not in IT myself altough I'm working for a software company - is it easy enough to do up a script to list the paths of the files and place them in excel? Is there like a format/draft I could use? If not I think I'll just leave it, no need to get to complicated - i'm happy with the amount of time I've just saved.


  • Registered Users, Registered Users 2 Posts: 1,562 ✭✭✭cance


    If you want to get the contents of the directory and all sub directories use

    dir /s /b >> list.txt

    Then import it Into excel using \ as the delimiter


  • Advertisement
Advertisement