{"id":6564,"date":"2014-01-30T21:51:20","date_gmt":"2014-01-30T21:51:20","guid":{"rendered":"https:\/\/test.simple-talk.com\/uncategorized\/4899\/"},"modified":"2016-07-28T10:54:37","modified_gmt":"2016-07-28T10:54:37","slug":"4899","status":"publish","type":"post","link":"https:\/\/www.red-gate.com\/simple-talk\/blogs\/4899\/","title":{"rendered":"Quick Tip: Windows directory file list"},"content":{"rendered":"<p>In a previous version of Windows (circa Windows95 or older) there was a button in the toolbar of it&#8217;s equivalent of Windows Explorer that generated a list of files in the open directory, in a text file. Despite searching through <a href=\"http:\/\/toastytech.com\/guis\/indexwindows.html\">http:\/\/toastytech.com\/guis\/indexwindows.html<\/a> I cant locate an image of it or find a demo of it in action but it was pretty useful at the time and I have longed for it to become a feature once again.<\/p>\n<p>Quite often you need to execute something from the command line and that generally means starting cmd.exe and then using a series of CD commands to get to the location of the exe you want to start. That or you have to open Windows Explorer to navigate where you want to go and then copy and right click, paste the path into the CD command to get there a little quicker.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh6.googleusercontent.com\/9ez4gDvqsor3SiYc2D7W_eP_9EPCAyETnoxA9PUS1sya2VULXy09lE2Z3QAWifi9t82LiW-lDEX7JwlOBuc4Z-OmExLNB51uGXeYogwgo1l7wya3_zffPx5x_w\" alt=\"9ez4gDvqsor3SiYc2D7W_eP_9EPCAyETnoxA9PUS\" \/><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh6.googleusercontent.com\/qaxYAIG7FfDwsbQMIzs-a0E7SvikQ9IYA9NNJ4Pfdr0BEYlw_s3yQL_C-OVq42qHaCqKrRiRiB7JxUNuG9YV7e9hapig1q5Id4_1JYs4DGp05l06mFXibZiMOg\" alt=\"qaxYAIG7FfDwsbQMIzs-a0E7SvikQ9IYA9NNJ4Pf\" \/><\/p>\n<p>No more.<\/p>\n<p>Open Windows Explorer and navigate to the directory you need.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh3.googleusercontent.com\/mbl-pGJBiLiiAgCUTJkg0x4GleVSysTTyBxsV_-s2SSB0hWn95r0Y9hxJtYUCtZnLDOB4t2vJcHIRWh8RoYv2Qs6NK6NhXWROePwSaDjh9Uhqz__gPAIBafBVQ\" alt=\"mbl-pGJBiLiiAgCUTJkg0x4GleVSysTTyBxsV_-s\" \/><\/p>\n<p>Press Alt + D.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh3.googleusercontent.com\/A8eoOojf8IQWmH8OmU7zbUJ3fROgup_WjaYw79_IKy7Ko88k2WvUSyL8vDj1wY0y3iWeAxdzKz5XXmN7sATS_ckSN0sC3YLEpRrXoL0Qakpg6CzHqbOoO2EPOA\" alt=\"A8eoOojf8IQWmH8OmU7zbUJ3fROgup_WjaYw79_I\" \/><\/p>\n<p>Your cursor is now in the address bar at the top of the window. Type cmd and press enter.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh5.googleusercontent.com\/qqXJDku6Uz-YgdTVjFYnDZP8-FhYvu1I7Ddok1Dfr0mE9sqdtaEh7o6sK5BIhkooalzJdcG5Oi9rxyvx7Nq56WL6Dr5PhRpyg6qjmZFNa88wT_97eR_2Jfs_cw\" alt=\"qqXJDku6Uz-YgdTVjFYnDZP8-FhYvu1I7Ddok1Df\" \/><\/p>\n<p>Hey presto! You now have a command window at the Windows location of your choosing.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh3.googleusercontent.com\/F0XBZsztoTpw7_soWKqVeNZ65LFHfAopWWZKP0ChMuAwPylz-4yvzkLD4LdbkGGaJ7Hz1QOuUHyEN9QpU_d-sAmoVb3DdduuhgzkqN_d1dBFeONzWM7BwGovIw\" alt=\"F0XBZsztoTpw7_soWKqVeNZ65LFHfAopWWZKP0Ch\" \/><\/p>\n<p>Now, getting back to the functionality mentioned at the start of this blog, if you want a list of the files in this directory simply type DIR \/B &gt; List.txt and press enter.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh3.googleusercontent.com\/bhS7Q70cb7HVB8-lvT7QVwUlnl8uQd_WwJC-wBvZAlmPf5RPHAnQHPobzUJQeX8ktVOrGwlSQekq9CX_rkNjed9eSJwRfgOS-waCSDASpdNUSJDZRpeu-8FToA\" alt=\"bhS7Q70cb7HVB8-lvT7QVwUlnl8uQd_WwJC-wBvZ\" \/><\/p>\n<p>You can now type Exit at the command prompt to close cmd.exe, or click the Close Window button.<\/p>\n<p>In Windows Explorer you will now find a file called List.txt that when you open it contains a list of the files in the directory.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh5.googleusercontent.com\/solpUA7yvDkZmxa5WWffL6BnoIL-jEj5oQH-C9r4M8sKDdtx1U0gIFh4MosNONfrgY59lR1O5LLlIDQO_d5LwOnmBmZmQQqSgCCR6LBlxhfOAg78CLbM8iN8cQ\" alt=\"solpUA7yvDkZmxa5WWffL6BnoIL-jEj5oQH-C9r4\" \/><\/p>\n<p><img decoding=\"async\" src=\"https:\/\/lh4.googleusercontent.com\/AuJLTtr91aKIonZpSCeoHWpOacWFajP1yNbBl2FgUR224V8cc-BpPwta75luwEW5ifpZXAUI-K0P0kCHxQs_0HpzoPlbPwHJMmV93o6Ckpr-24AVi5NDr9M4Mw\" alt=\"AuJLTtr91aKIonZpSCeoHWpOacWFajP1yNbBl2Fg\" \/><\/p>\n<p>While we are staring  at the Tools directory on my laptop this is another great opportunity to remind everyone about the great suite of tools from sysinternals and to recommend using the <a href=\"http:\/\/goo.gl\/qGb3tk\">SyncTools app from Kenny Kerr <\/a>to keep them all up to date.<\/p>\n<p>Hope this helps!<\/p>\n<p>If you can refer me to a source that names the tool, the version of Windows it was in or even better shows it in action then I would be very impressed, please let me know in the comments.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In a previous version of Windows (circa Windows95 or older) there was a button in the toolbar of it&#8217;s equivalent of Windows Explorer that generated a list of files in the open directory, in a text file. Despite searching through http:\/\/toastytech.com\/guis\/indexwindows.html I cant locate an image of it or find a demo of it in&#8230;&hellip;<\/p>\n","protected":false},"author":101210,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[2],"tags":[],"coauthors":[],"class_list":["post-6564","post","type-post","status-publish","format-standard","hentry","category-blogs"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts\/6564","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/users\/101210"}],"replies":[{"embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/comments?post=6564"}],"version-history":[{"count":5,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts\/6564\/revisions"}],"predecessor-version":[{"id":42363,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts\/6564\/revisions\/42363"}],"wp:attachment":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/media?parent=6564"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/categories?post=6564"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/tags?post=6564"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/coauthors?post=6564"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}