DOS Command dir
#2
Posted 25 November 2010 - 09:23 AM
DIR command lists the contents of the a folder. If you give just DIR command without any parameters, then it will list the contents of the current folder. If you give the folder path like DIR C:\Windows then it will list the contents of that folder. How the contents are displayed and which contents are displayed, depends upon various switches like /P /E /A etc.
http://en.wikipedia.org/wiki/Dir_%28command%29
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/dir.mspx
#3
Posted 14 December 2010 - 02:21 AM
#4
Posted 14 December 2010 - 08:33 AM
#5
Posted 27 December 2010 - 07:34 AM
Nisha Haridas, on 25 November 2010 - 05:40 AM, said:
Hello,
I hope everything is OK.
I want "dir" latest date. For example in any directory there 5 files. Like below;
created date 12.27.2010 10:00 a.txt
created date 12.27.2010 11:00 b.txt
created date 10.27.2010 09:00 c.txt
created date 09.27.2010 10:00 d.txt
created date 09.27.2010 11:00 e.txt
and I want to list just specified date for example
created date 12.27.2010 a.txt
created date 12.27.2010 b.txt
only both of them.
How can I do? It is possible
#6
Posted 28 December 2010 - 02:56 PM
You cannot (at least as far as I know) restrict the dir command to a specific date range.
However you can have it sort the list with the most recent on top
The syntax would be
dir /o-d
Here is a link to all the switches for the dir command
#7
Posted 18 January 2011 - 12:44 AM
#8
Posted 06 March 2011 - 09:44 AM
#9
Posted 06 March 2011 - 09:52 AM
#10
Posted 06 March 2011 - 11:39 AM
BleepingComputer has a tutorial : http://www.bleepingcomputer.com/tutorials/windows-command-prompt-introduction/
#11
Posted 07 March 2011 - 02:10 PM
Many of us here are well versed in MSDOS.
We would be more than happy to answer any questions you may have about it.
May I suggest though that you start your own thread for such so that your posts do not get overlooked or burried.
#12
Posted 18 March 2012 - 11:19 AM
Try something like this?
@ECHO OFF
set /p in=-
for /f "tokens=1*" %%a in ('dir') do IF "%%a"=="%in%" (CLS&ECHO %
You could also use findstr.
This post has been edited by dnthns87: 18 March 2012 - 11:19 AM

Help

Back to top











