Rob Rudloff
asked on
BATCH find highest numbered .jpg and save in a variable ?
Hi.
I have a folder with many .jpg files.
I need a Windows batch program to find the highest numbered file + 1 and save it to a variable.
So, I have in my folder:
Any suggestions for me to try?
Thanks!
I have a folder with many .jpg files.
I need a Windows batch program to find the highest numbered file + 1 and save it to a variable.
So, I have in my folder:
211-25.jpg
215-01.jpg
215-04.jpg
218-03.jpg
218-12.jpg
and i want a batch file that i will send a prefix to, like "215" then have it return an integer equal to the last in the series + 1, so it would return "5".Any suggestions for me to try?
Thanks!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
(Yes, the format of the "suffix" is always -XX and never -XXX)
Thanks a lot -- I never would have figured that one out.
--- Rob