| Forum Home | ||||
| Press F1 | ||||
| Thread ID: 138774 | 2015-01-21 23:42:00 | copying file names | aceterry (17330) | Press F1 |
| Post ID | Timestamp | Content | User | ||
| 1392491 | 2015-01-21 23:42:00 | Hi, I have an WD external hard drive,when I plug to my laptop via USB,up comes the contents of this drive.What I am trying to do is copy the file names without copying the files so that I can print a list of whats on the h/drive. Hope this makes sense !! | aceterry (17330) | ||
| 1392492 | 2015-01-21 23:57:00 | You could do something like this: Open a command prompt - Start - Run - cmd Type in dir h: > c:\files.txt That will create a file called files.txt on your C: with a list of the files/folders that show on your usb drive. You can open and view it and then print if you want. If you need to see all files and folders, even those inside the folders on the root H: then use: dir /s h: > c:\files.txt This is going from memory and I haven't done that for a long time so hopefully it is correct. :D |
CYaBro (73) | ||
| 1392493 | 2015-01-22 00:10:00 | You could do something like this: Open a command prompt - Start - Run - cmd Type in dir h: > c:\files.txt That will create a file called files.txt on your C: with a list of the files/folders that show on your usb drive. You can open and view it and then print if you want. If you need to see all files and folders, even those inside the folders on the root H: then use: dir /s h: > c:\files.txt This is going from memory and I haven't done that for a long time so hopefully it is correct. :D Almost... Open command prompt as above... When finished 'exit' + ENTER to close command window dir h: /s > c:\files.txt Full "dir" switches... (from dir /?) Displays a list of files and subdirectories in a directory. DIR [filename] [/A[[:]attributes]] [/B] [/C] [/L] [/N] [/O[[:]sortorder]] [/Q] [/R] [/S] [/T[[:]timefield]] [/W] [/X] [/4] [drive:][path][filename] Specifies drive, directory, and/or files to list. /A Displays files with specified attributes. attributes D Directories R Read-only files H Hidden files A Files ready for archiving S System files I Not content indexed files L Reparse Points - Prefix meaning not /B Uses bare format (no heading information or summary). /C Display the thousand separator in file sizes. This is the default. Use /-C to disable display of separator. /D Same as wide but files are list sorted by column. /L Uses lowercase. /N New long list format where filenames are on the far right. /O List by files in sorted order. sortorder N By name (alphabetic) S By size (smallest first) E By extension (alphabetic) D By date/time (oldest first) G Group directories first - Prefix to reverse order /P Pauses after each screenful of information. /Q Display the owner of the file. /R Display alternate data streams of the file. /S Displays files in specified directory and all subdirectories. /T Controls which time field displayed or used for sorting timefield C Creation A Last Access W Last Written /W Uses wide list format. /X This displays the short names generated for non-8dot3 file names. The format is that of /N with the short name inserted before the long name. If no short name is present, blanks are displayed in its place. /4 Displays four-digit years Switches may be preset in the DIRCMD environment variable. Override preset switches by prefixing any switch with - (hyphen)--for example, /-W. |
ManUFan (7602) | ||
| 1392494 | 2015-01-22 02:48:00 | Yup, or open notepad, copy and paste that command line into it, save the file as say dirlist.bat You could remove the h: parameter then copy the bat file to the root directory and it will work, reason being it will then work for any drive letter as long as you run it from the root dir of that drive. to the root directory |
dugimodo (138) | ||
| 1392495 | 2015-01-29 23:35:00 | Hi, tried all these things ,but no luck.Tried displaying files on external drive and do screen print which I pasted to "MS word"but then left with the whole page and not able to delete the parts I don't want. | aceterry (17330) | ||
| 1392496 | 2015-01-30 01:05:00 | Try explorer. Select all files (control A). Right click and hold shift key. Has option to choose copy path names (or similar). Then paste. | kahawai chaser (3545) | ||
| 1392497 | 2015-01-30 01:16:00 | Or maybe this may help. www.karenware.com |
ruup (1827) | ||
| 1392498 | 2015-01-30 01:43:00 | try Tree H: /F >> c:\dir.txt from cmd prompt | beama (111) | ||
| 1392499 | 2015-01-30 04:20:00 | Those suggestions do work, you sure you understand what to do? To create a basic batch file try this (you can get fancier once it's working if you like) Open notepad Cut and paste this into it: dir /s > files.txt click file - save as - Save as type "all files" - name it dirlist.bat find that bat file, copy it to the drive, double click it, a txt file called files.txt appears, double click it and there's a txt list of the directory. It's a simplified version of above suggestions that'll create the file in the same place it's run from so you just leave it in the root directory of the drive. Otherwise try ruup's suggestion or one of the ones here www.makeuseof.com |
dugimodo (138) | ||
| 1392500 | 2015-01-30 05:56:00 | Yeah, I do a similar thing. My two techniques have both been mentioned. My lazy way... Start> Command Prompt (or just CMD) H: (or other drive letter) Dir *.* /s >>H.txt Alternative, if looking for only mpg files on the drive: Dir *.mpg /s >>H.txt But as already said, if saved as a Bat file, then all reference to the drive letter can be omitted, just copy the bat to the drive, and run it. I use this technique to get a Dir list of all my drives. I import the results into MS Access, then use a (tedious) routine to compare file sizes and dates to determine where duplicates exist, and their quantities ( eg to ensure 2 backups of all files, each should have a file count of 3 or more). There are duplicate file finders on the net with similar functionality, which do a hash check as well, but these are no quicker. |
Paul.Cov (425) | ||
| 1 2 | |||||