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. dir /B >files.txt

dir /B >files.txt

Scheduled Pinned Locked Moved The Lounge
pythoncomquestionlearning
30 Posts 15 Posters 3 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.
  • J Jochen Arndt

    Using that you can't see what is listed. You have to use

    dir /b >files.txt & type files.txt

    instead :)

    M Offline
    M Offline
    Marc Clifton
    wrote on last edited by
    #3

    But I don't want to see it, I just want to send the list of files to someone. ;) Marc

    Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

    1 Reply Last reply
    0
    • M Marc Clifton

      Seriously? In the world of self driving cars, AI stock brokers, and a fake White House, to get a listing of files in a folder I have to open a console window and do that? Marc

      Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #4

      a.) Open your Directory in Windows Explorer b.) In the adress bar type e.g.

      dir | c:\windows\system32\clip

      or instead of dir, also tree or what else. This will pipe the Output to clipboard :) And in case sys32 is in the path it becomes also a little bit shorter command ;) Bruno [Edit] The basics for this I learned here at CP. What I remember is, it was also in the Lounge when somebody described that one can Launch cmd directly by the adress bar in the Windows Explorer. :-O [Edit 1] Finally I found the source: https://www.codeproject.com/Lounge.aspx?fid=1159&select=5367179&fr=5076#xx0xx posted by [virang_21 - Professional Profile](https://www.codeproject.com/script/Membership/View.aspx?mid=6555380)

      J G Richard DeemingR M 4 Replies Last reply
      0
      • M Marc Clifton

        Seriously? In the world of self driving cars, AI stock brokers, and a fake White House, to get a listing of files in a folder I have to open a console window and do that? Marc

        Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

        OriginalGriffO Offline
        OriginalGriffO Offline
        OriginalGriff
        wrote on last edited by
        #5

        You can go direct to the clipboard - dir | clip will do it. But I agree, it's a bit poor all round. There are apps out there to do it - and it's simple enough to add one of your own!

        Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

        "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
        "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

        L 1 Reply Last reply
        0
        • OriginalGriffO OriginalGriff

          You can go direct to the clipboard - dir | clip will do it. But I agree, it's a bit poor all round. There are apps out there to do it - and it's simple enough to add one of your own!

          Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

          L Offline
          L Offline
          Lost User
          wrote on last edited by
          #6

          That is plagarized from the message above ;P :laugh: Bruno

          OriginalGriffO 1 Reply Last reply
          0
          • L Lost User

            a.) Open your Directory in Windows Explorer b.) In the adress bar type e.g.

            dir | c:\windows\system32\clip

            or instead of dir, also tree or what else. This will pipe the Output to clipboard :) And in case sys32 is in the path it becomes also a little bit shorter command ;) Bruno [Edit] The basics for this I learned here at CP. What I remember is, it was also in the Lounge when somebody described that one can Launch cmd directly by the adress bar in the Windows Explorer. :-O [Edit 1] Finally I found the source: https://www.codeproject.com/Lounge.aspx?fid=1159&select=5367179&fr=5076#xx0xx posted by [virang_21 - Professional Profile](https://www.codeproject.com/script/Membership/View.aspx?mid=6555380)

            J Offline
            J Offline
            Jeremy Falcon
            wrote on last edited by
            #7

            Holy hell. I never knew this!

            Jeremy Falcon

            L 1 Reply Last reply
            0
            • L Lost User

              That is plagarized from the message above ;P :laugh: Bruno

              OriginalGriffO Offline
              OriginalGriffO Offline
              OriginalGriff
              wrote on last edited by
              #8

              Unintentionally - but you don't need the path (and it works in all versions since Vista)

              Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

              "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
              "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

              L 1 Reply Last reply
              0
              • J Jeremy Falcon

                Holy hell. I never knew this!

                Jeremy Falcon

                L Offline
                L Offline
                Lost User
                wrote on last edited by
                #9

                This I learned here in CP :) Unfortnatelly I can't find the post where it was described/mentioned to give credit to :(

                1 Reply Last reply
                0
                • L Lost User

                  a.) Open your Directory in Windows Explorer b.) In the adress bar type e.g.

                  dir | c:\windows\system32\clip

                  or instead of dir, also tree or what else. This will pipe the Output to clipboard :) And in case sys32 is in the path it becomes also a little bit shorter command ;) Bruno [Edit] The basics for this I learned here at CP. What I remember is, it was also in the Lounge when somebody described that one can Launch cmd directly by the adress bar in the Windows Explorer. :-O [Edit 1] Finally I found the source: https://www.codeproject.com/Lounge.aspx?fid=1159&select=5367179&fr=5076#xx0xx posted by [virang_21 - Professional Profile](https://www.codeproject.com/script/Membership/View.aspx?mid=6555380)

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

                  :thumbsup: Old dog, new trick. Thanks!

                  Software Zen: delete this;

                  L 1 Reply Last reply
                  0
                  • G Gary Wheeler

                    :thumbsup: Old dog, new trick. Thanks!

                    Software Zen: delete this;

                    L Offline
                    L Offline
                    Lost User
                    wrote on last edited by
                    #11

                    Thank you, I learned this here at CP :)

                    1 Reply Last reply
                    0
                    • OriginalGriffO OriginalGriff

                      Unintentionally - but you don't need the path (and it works in all versions since Vista)

                      Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

                      L Offline
                      L Offline
                      Lost User
                      wrote on last edited by
                      #12

                      On my W7 it does not work wothout path. But this most probably because I mixed up the path by myself.

                      1 Reply Last reply
                      0
                      • M Marc Clifton

                        Seriously? In the world of self driving cars, AI stock brokers, and a fake White House, to get a listing of files in a folder I have to open a console window and do that? Marc

                        Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

                        P Online
                        P Online
                        PIEBALDconsult
                        wrote on last edited by
                        #13

                        "Use the right to for the right job." I use the command-line all day.

                        M 1 Reply Last reply
                        0
                        • M Marc Clifton

                          Seriously? In the world of self driving cars, AI stock brokers, and a fake White House, to get a listing of files in a folder I have to open a console window and do that? Marc

                          Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

                          V Offline
                          V Offline
                          Vark111
                          wrote on last edited by
                          #14

                          1. Open folder in Explorer 2. Take screen shot 3. Open Paint 4. Paste Screen shot 5. Print image 6. Scan printed paper using a flatbed scanner 7. Run scanner's OCR software to convert to text 8. Save text to floppy disk 9. Take digital photo of floppy disk 10. Email digital photo to recipient

                          L OriginalGriffO 2 Replies Last reply
                          0
                          • V Vark111

                            1. Open folder in Explorer 2. Take screen shot 3. Open Paint 4. Paste Screen shot 5. Print image 6. Scan printed paper using a flatbed scanner 7. Run scanner's OCR software to convert to text 8. Save text to floppy disk 9. Take digital photo of floppy disk 10. Email digital photo to recipient

                            L Offline
                            L Offline
                            Lost User
                            wrote on last edited by
                            #15

                            Optional 3.a) Take a paper and write it down and proceed with "6."

                            1 Reply Last reply
                            0
                            • V Vark111

                              1. Open folder in Explorer 2. Take screen shot 3. Open Paint 4. Paste Screen shot 5. Print image 6. Scan printed paper using a flatbed scanner 7. Run scanner's OCR software to convert to text 8. Save text to floppy disk 9. Take digital photo of floppy disk 10. Email digital photo to recipient

                              OriginalGriffO Offline
                              OriginalGriffO Offline
                              OriginalGriff
                              wrote on last edited by
                              #16

                              Vark111 wrote:

                              10. Email fax digital photo to recipient

                              FTFY!

                              Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

                              "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
                              "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

                              L V 2 Replies Last reply
                              0
                              • L Lost User

                                a.) Open your Directory in Windows Explorer b.) In the adress bar type e.g.

                                dir | c:\windows\system32\clip

                                or instead of dir, also tree or what else. This will pipe the Output to clipboard :) And in case sys32 is in the path it becomes also a little bit shorter command ;) Bruno [Edit] The basics for this I learned here at CP. What I remember is, it was also in the Lounge when somebody described that one can Launch cmd directly by the adress bar in the Windows Explorer. :-O [Edit 1] Finally I found the source: https://www.codeproject.com/Lounge.aspx?fid=1159&select=5367179&fr=5076#xx0xx posted by [virang_21 - Professional Profile](https://www.codeproject.com/script/Membership/View.aspx?mid=6555380)

                                Richard DeemingR Offline
                                Richard DeemingR Offline
                                Richard Deeming
                                wrote on last edited by
                                #17

                                That doesn't seem to work from the Explorer address bar in Windows 10. It just opens the default browser and searches for "dir | c:\windows\system32\clip" - and to make matters worse, it searches with Bing! :doh: I guess I should be grateful that they're honouring my default browser, even if they're going to ignore my default search engine.


                                "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

                                "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

                                L J T 3 Replies Last reply
                                0
                                • OriginalGriffO OriginalGriff

                                  Vark111 wrote:

                                  10. Email fax digital photo to recipient

                                  FTFY!

                                  Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

                                  L Offline
                                  L Offline
                                  Lost User
                                  wrote on last edited by
                                  #18

                                  OriginalGriff wrote:

                                  10. Email fax Homing Pigeon digital photo to recipient

                                  FTFY!

                                  Speed of sound - 1100 ft/sec Speed of light - 186,000 mi/sec Speed of stupid - instantaneous.

                                  1 Reply Last reply
                                  0
                                  • Richard DeemingR Richard Deeming

                                    That doesn't seem to work from the Explorer address bar in Windows 10. It just opens the default browser and searches for "dir | c:\windows\system32\clip" - and to make matters worse, it searches with Bing! :doh: I guess I should be grateful that they're honouring my default browser, even if they're going to ignore my default search engine.


                                    "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

                                    L Offline
                                    L Offline
                                    Lost User
                                    wrote on last edited by
                                    #19

                                    Thank you for your Feedback. W7, private Laptop: Ok W8.1, Company Desktop: Same what you reported :( W10: not tested... I think there will be some tricks to make it work also for W8/10

                                    1 Reply Last reply
                                    0
                                    • M Marc Clifton

                                      Seriously? In the world of self driving cars, AI stock brokers, and a fake White House, to get a listing of files in a folder I have to open a console window and do that? Marc

                                      Latest Article - Merkle Trees Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny Artificial intelligence is the only remedy for natural stupidity. - CDP1802

                                      Z Offline
                                      Z Offline
                                      Z C M
                                      wrote on last edited by
                                      #20

                                      From Windows Explorer. Open the folder you which to copy your list of files from. Select all the files you want included. Hold down Shift and right click. Select Copy as path. I don't remember where I found this, but it will copy the list of files and their path to the clipboard. Once pasted into a text editor, or whatever, you will see something like this. "C:\Users\\Pictures\File1.gif" "C:\Users\\Pictures\File2.jpg" "C:\Users\\Pictures\File3.png" "C:\Users\\Pictures\File4.jpg" "C:\Users\\Pictures\File5.jpg" Note, this is not recursive. It will not dig into sub-folders. It will only copy the path of visible and selected files/folders. I also do not know if it will work with Windows 10.

                                      "...JavaScript could teach Dyson how to suck." -- Nagy Vilmos

                                      Richard DeemingR 1 Reply Last reply
                                      0
                                      • Z Z C M

                                        From Windows Explorer. Open the folder you which to copy your list of files from. Select all the files you want included. Hold down Shift and right click. Select Copy as path. I don't remember where I found this, but it will copy the list of files and their path to the clipboard. Once pasted into a text editor, or whatever, you will see something like this. "C:\Users\\Pictures\File1.gif" "C:\Users\\Pictures\File2.jpg" "C:\Users\\Pictures\File3.png" "C:\Users\\Pictures\File4.jpg" "C:\Users\\Pictures\File5.jpg" Note, this is not recursive. It will not dig into sub-folders. It will only copy the path of visible and selected files/folders. I also do not know if it will work with Windows 10.

                                        "...JavaScript could teach Dyson how to suck." -- Nagy Vilmos

                                        Richard DeemingR Offline
                                        Richard DeemingR Offline
                                        Richard Deeming
                                        wrote on last edited by
                                        #21

                                        Z.C.M. wrote:

                                        I also do not know if it will work with Windows 10.

                                        Works for me. :thumbsup:


                                        "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

                                        "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

                                        1 Reply Last reply
                                        0
                                        • OriginalGriffO OriginalGriff

                                          Vark111 wrote:

                                          10. Email fax digital photo to recipient

                                          FTFY!

                                          Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

                                          V Offline
                                          V Offline
                                          Vark111
                                          wrote on last edited by
                                          #22

                                          Dang, I knew there was one or two more absurd steps I could add. :)

                                          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