Forums65
Topics76,361
Posts1,033,315
Members14,578
|
Most Online16,551 Feb 2nd, 2024
|
|
5 members (2 invisible),
9,740
guests, and
374
robots. |
Key:
Admin,
Global Mod,
Mod
|
|
M |
T |
W |
T |
F |
S |
S |
1
|
2
|
3
|
4
|
5
|
6
|
7
|
8
|
9
|
10
|
11
|
12
|
13
|
14
|
15
|
16
|
17
|
18
|
19
|
20
|
21
|
22
|
23
|
24
|
25
|
26
|
27
|
28
|
29
|
30
|
|
|
|
|
|
|
|
Joined: Oct 2008
Posts: 5,210
Forum Veteran
|
OP
Forum Veteran
Joined: Oct 2008
Posts: 5,210 |
When using xp if I go to start then search if I type in .jpeg it comes up with all the jpegs or whatever file extension I put in. What I'd like would be a program that would do the same but would enable me to make an excel list of them. Got loads of mobi,jpeg,txt and pdf to sort out in various folders. Been at it for a couple of days trying to sort
Could someone put the run-cmd lineon here in simple terms where to put the folder and file type if that works Thanks
Last edited by derekdwc; 22nd Feb 2013 3:49pm.
|
|
|
|
Joined: Jan 2009
Posts: 10
Newbeee
|
Newbeee
Joined: Jan 2009
Posts: 10 |
Choose Start/Programs/Accessories/notepad to load a version of notepad
In notepad type in the following line of text......
dir c:\*.jp* /s > c:\users\yourwindowsname\desktop\output.txt
In the above replace "yourwindowsname" with whatever your windows login name is. then click File / Save and save the file on your desktop however you MUST call the file so that it has .bat at the end e.g. call it myprogram.bat - do not call it myprogram.txt otherwise it will not work. It is important that the filename ends .bat so that it knows it is a batch program
You can run this 'batch program - c:\myprogram.bat' by double clicking on it in windows explorer
You should then see a file called output.txt appear on your desktop when it has finished showing all .jpg or .jpeg files
You can use same code and replace *.jp* with *.txt for text files *.xls* for excel files, *.doc* for word files etc. or *.* file all files. The /s means look in all sub directories.
|
|
|
|
Joined: Jul 2012
Posts: 230
Addict
|
Addict
Joined: Jul 2012
Posts: 230 |
|
|
|
|
Joined: Mar 2012
Posts: 8
Beginner
|
Beginner
Joined: Mar 2012
Posts: 8 |
From the command prompt, use this:
DIR <StartDir> *.jpg,*.pdf,*.ext /b /s >files.csv
Where <StartDir> is the 'root' of where you want to start the search from (eg C:\ for start from C: drive root.
You can have more file types to search than those three, obviously! Just change/add what you want to search for.
The list of files will be written into the file 'files.csv'. This will be able to be opened directly in Excel.
There's plenty of other switches that DIR can use simply enter DIR /? to see them.
|
|
|
|
Joined: Nov 2003
Posts: 21,269 Likes: 4
Wiki Master
|
Wiki Master
Joined: Nov 2003
Posts: 21,269 Likes: 4 |
Derek if your stuck,I can help you Doing the above. It's easy when you have been shown how.
Batch programs if not done correctly can do a lot of damage if you change the command. In this case DIR is the command.
If your on the wikiwalk on Sunday I can give you some pointers / help.
|
|
|
|
Joined: Oct 2008
Posts: 5,210
Forum Veteran
|
OP
Forum Veteran
Joined: Oct 2008
Posts: 5,210 |
THANKS Bought the pro version. Does what I wanted
|
|
|
Click to View Topic.
|
|
Posts: 14,350
Joined: July 2008
|
|
There are no members with birthdays on this day. |
|
|
|