Search found 1 match

by rootx
09 May 2014 07:17
Forum: DOS Batch Forum
Topic: How can i order the results consecutively in a batch?
Replies: 13
Views: 15057

How can i order the results consecutively in a batch?

Example file list:

Code: Select all

1.jpg
2.jpg
3.jpg
22.jpg


easy cycle for iterating the list

Code: Select all

for /r %j in (*.jpg) do @echo %~nxj


that's the result....

Code: Select all

1
2
22
3


How can i order the results consecutively, like below?

Code: Select all

1
2
3
22


thanks everyone