Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Creating a list of file paths

Creating a list of file paths

Scheduled Pinned Locked Moved The Lounge
databasewindows-admin
16 Posts 9 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L lost in transition

    :omg: Large file.


    God Bless, Jason
    I am not perfect but I try to be better than those before me. So those who come after me will be better than I am.

    F Offline
    F Offline
    Farhan Noor Qureshi
    wrote on last edited by
    #5

    That was meant for reference only.


    Farhan Noor Qureshi

    1 Reply Last reply
    0
    • F Farhan Noor Qureshi

      Try this: dir C:\*.* /s > AllFilesAndFolders.txt


      Farhan Noor Qureshi

      P Offline
      P Offline
      PIEBALDconsult
      wrote on last edited by
      #6

      And add a /B too

      F 1 Reply Last reply
      0
      • C Chris McGlothen

        My company is getting ready to revamp our intranet and have a desire to clean out our servers of all files, documents and applications that are not being used. I've already loaded all the IIS log files into a SQL table for the past 15 months and am looking for a way to compile a complete list of all file paths ("C:\apps\test\default.asp") in the form of a text file that I can then load into a seperate table and do some cross checking. Any hints/solutions are greatly appreciated.


        An American football fan - Go Seahawks! Lil Turtle

        G Offline
        G Offline
        Gary Wheeler
        wrote on last edited by
        #7

        Simple solution:

        1. Delete everything.
        2. Restore those items people complain about.

        After a month or two, things should have stabilized to only those items that are actually in use. (Sorry; I'm wasting time twiddling my thumbs engaging in offline research during the last hour of the day before vacation, so my facetious quotient is off the scale)


        Software Zen: delete this;

        C 1 Reply Last reply
        0
        • D David Crow

          As you'll likely be needing code of some sort, you might have a bit more luck with this here.


          "A good athlete is the result of a good and worthy opponent." - David Crow

          "To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne

          C Offline
          C Offline
          Chris McGlothen
          wrote on last edited by
          #8

          Thanks for the suggestion:), but what I'm trying to do is get a text list of the directory paths first then I can worry about loading the list into the database. i.e. "C:\ File Folder" "C:\apps\TrackIt\default.aspx 12 KB ASP.NET Server Page" "C:\apps\TrackIt\default.aspx.cs 15 KB Visual C# Source File" . . . . "C:\docs\HR\Employee Policies.doc 124 KB Microsoft Word Document" The actual path is what I'd like to check the log files against. I appreciate the help, though.


          An American football fan - Go Seahawks! Lil Turtle

          1 Reply Last reply
          0
          • P PIEBALDconsult

            And add a /B too

            F Offline
            F Offline
            Farhan Noor Qureshi
            wrote on last edited by
            #9

            Thanks for the suggestion.

            /B
            

            can be very handy. -- modified at 15:53 Thursday 27th September, 2007


            Farhan Noor Qureshi

            1 Reply Last reply
            0
            • C Chris McGlothen

              My company is getting ready to revamp our intranet and have a desire to clean out our servers of all files, documents and applications that are not being used. I've already loaded all the IIS log files into a SQL table for the past 15 months and am looking for a way to compile a complete list of all file paths ("C:\apps\test\default.asp") in the form of a text file that I can then load into a seperate table and do some cross checking. Any hints/solutions are greatly appreciated.


              An American football fan - Go Seahawks! Lil Turtle

              P Offline
              P Offline
              peterchen
              wrote on last edited by
              #10

              Farhan almost nailed it

              dir basepath /b /s >files.txt

              gives all file and folder names recursively, one full file or folder path per line. This is what I found easiest to work with. Use

              dir basepath /b /s /A:D >files.txt

              to list only directories and

              dir basepath /b /s /A:D- >files.txt

              to list only files


              We are a big screwed up dysfunctional psychotic happy family - some more screwed up, others more happy, but everybody's psychotic joint venture definition of CP
              My first real C# project | Linkify!|FoldWithUs! | sighist

              C 1 Reply Last reply
              0
              • C Chris McGlothen

                My company is getting ready to revamp our intranet and have a desire to clean out our servers of all files, documents and applications that are not being used. I've already loaded all the IIS log files into a SQL table for the past 15 months and am looking for a way to compile a complete list of all file paths ("C:\apps\test\default.asp") in the form of a text file that I can then load into a seperate table and do some cross checking. Any hints/solutions are greatly appreciated.


                An American football fan - Go Seahawks! Lil Turtle

                C Offline
                C Offline
                Chris McGlothen
                wrote on last edited by
                #11

                I've found the answer! There is a app called DDFileCatcher that will scan an entire drive and return all the file paths.:-D


                An American football fan - Go Seahawks! Lil Turtle

                P 1 Reply Last reply
                0
                • P peterchen

                  Farhan almost nailed it

                  dir basepath /b /s >files.txt

                  gives all file and folder names recursively, one full file or folder path per line. This is what I found easiest to work with. Use

                  dir basepath /b /s /A:D >files.txt

                  to list only directories and

                  dir basepath /b /s /A:D- >files.txt

                  to list only files


                  We are a big screwed up dysfunctional psychotic happy family - some more screwed up, others more happy, but everybody's psychotic joint venture definition of CP
                  My first real C# project | Linkify!|FoldWithUs! | sighist

                  C Offline
                  C Offline
                  Chris McGlothen
                  wrote on last edited by
                  #12

                  Thanks, I'll save this in my snippet reference sheet.:)


                  An American football fan - Go Seahawks! Lil Turtle

                  1 Reply Last reply
                  0
                  • G Gary Wheeler

                    Simple solution:

                    1. Delete everything.
                    2. Restore those items people complain about.

                    After a month or two, things should have stabilized to only those items that are actually in use. (Sorry; I'm wasting time twiddling my thumbs engaging in offline research during the last hour of the day before vacation, so my facetious quotient is off the scale)


                    Software Zen: delete this;

                    C Offline
                    C Offline
                    Chris McGlothen
                    wrote on last edited by
                    #13

                    :laugh: Nice!!! If it wasn't the 'suggestion' of the CEO I'd probably consider it.


                    An American football fan - Go Seahawks! Lil Turtle

                    1 Reply Last reply
                    0
                    • C Chris McGlothen

                      I've found the answer! There is a app called DDFileCatcher that will scan an entire drive and return all the file paths.:-D


                      An American football fan - Go Seahawks! Lil Turtle

                      P Offline
                      P Offline
                      Paul Watson
                      wrote on last edited by
                      #14

                      Seriously, what peterchen and Farhan suggest works. And it is free plus you already have it. dir works. :)

                      regards, Paul Watson Ireland & South Africa

                      Andy Brummer wrote:

                      Watson's law: As an online discussion of cars grows longer, the probability of a comparison involving the Bugatti Veyron approaches one.

                      1 Reply Last reply
                      0
                      • C Chris McGlothen

                        My company is getting ready to revamp our intranet and have a desire to clean out our servers of all files, documents and applications that are not being used. I've already loaded all the IIS log files into a SQL table for the past 15 months and am looking for a way to compile a complete list of all file paths ("C:\apps\test\default.asp") in the form of a text file that I can then load into a seperate table and do some cross checking. Any hints/solutions are greatly appreciated.


                        An American football fan - Go Seahawks! Lil Turtle

                        G Offline
                        G Offline
                        GuyThiebaut
                        wrote on last edited by
                        #15

                        At the risk of being a pain... I wrote an application which will do this. I'm not just trying to flog my software as I wrote it to do the sort of thing you are after. Visit my website at wwww.tebofile.com where you can download a trial version of tebofile. The trial is good for 31 days. This allows you to scan a path(including network paths) and view output the results to a csv file. Let me know if it does the job

                        You always pass failure on the way to success.

                        C 1 Reply Last reply
                        0
                        • G GuyThiebaut

                          At the risk of being a pain... I wrote an application which will do this. I'm not just trying to flog my software as I wrote it to do the sort of thing you are after. Visit my website at wwww.tebofile.com where you can download a trial version of tebofile. The trial is good for 31 days. This allows you to scan a path(including network paths) and view output the results to a csv file. Let me know if it does the job

                          You always pass failure on the way to success.

                          C Offline
                          C Offline
                          Chris McGlothen
                          wrote on last edited by
                          #16

                          Thanks, I'll give it a go.


                          An American football fan - Go Seahawks! Lil Turtle

                          1 Reply Last reply
                          0
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • World
                          • Users
                          • Groups