* wildcard and choosing the most recent folder

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
Fage'
Posts: 1
Joined: 05 May 2009 09:39

* wildcard and choosing the most recent folder

#1 Post by Fage' » 05 May 2009 09:45

Hello Everyone

I have a batch file that looks like this

open edi_master1
ftpmdm
Ftp!mdm

lcd R:\05.05*
cd meterdata
cd
cd ..


Quit

the line lcd R:\05.05* enters into a folder that is named by some sort of date time stamp.

It always chooses the lowest folder (one that has the lowest stamp).

I want it to choose the most recent folder. How would i do that?

-Fage'

Post Reply