Windows 8 and 8.1 Forums

Run all batch files that exist within a folder?

  1. #1

    Posts : 7
    Windows 8 Pro with WMC

    Run all batch files that exist within a folder?


    I recently suffered an SSD failure, but luckily i was able to recover the files using @active's boot disk. The issue is that the files i recovered require that their file names be long, @active saves them as short file names due to DOS limitations, and creates a batch file that i can run to return them to their previous (long) name.

    The issue is i have over 500 folders, and this will take a very long time.

    Is there away to run all batch files in a folder (including subfolders) or is there a way to run all batch files with a certain name? (they are all named !_RENAME.bat).

    Any tips or ideas would be appreciated!

      My System SpecsSystem Spec

  2. #2

    Posts : 2,130
    Windows 8.0 x64

    See the /R switch in For command for command prompt

    Microsoft Corporation

    The way to get them all would be to put the folders all underneath one folder. Like C:\MyBatches or something.. if they are not already under one root folder. Open a command prompt in drive C: then do
    cd \MyBatches
    for /R %s in (*.bat) do %s

    Edit: Also you can look in the .bat. If it is a simple command to change to long filenames you can do it directly. But since the bats are already there... I would sample a few and make sure there's nothing that looks dangerous like del *.* or anything suspicious.
      My System SpecsSystem Spec

Run all batch files that exist within a folder?
Related Threads
I have a large collection of car photos spanning several years and growing, +300,000. I am now trying to combine them by year of make. There are many files with the same name like "1930 CarMakerName." I cannot take the time to review every conflict at transfer time, much quicker and easier to... I ordered a bunch of music off amazon tonight with their new amazon music program..3 albums. I went to move the albums from their download location to the proper music folder..and it gives me a 'item not found' error... I go 'ok..wait..what the frak? I'm staring at the bloody thing!' ...
Hello all, I wondering if anyone can tell me whether or not these batch files that I use to clear the Event Viewer logs and to activate the extended disk cleanup prompt of windows 7 are compatible with Windows 8.1. -Event Viewer log clean up batch file @echo offFOR /F "tokens=1,2*" %%V IN...
My new HP Pavilion with MS Win 8.1 includes all of the default MS Win sound files. I cannot access them to play for all users (family use with no password on accounts). REQUEST: I would like a 'How-To' on both accessing and getting MS Win 8.1 default or any sound file them to play during a...
I have: x4 .gif images, x14 .jpg images, and x5 .png images in my C:\Users\SampleUser\Downloads\img14 folder and want to move them to these desired locations via cmd. Move the x4 .gif images to: C:\Users\SampleUser\Downloads\img14\.gif Move the x14 .jpg images to:...
DOS is not dead, at least not yet for me. However in Windows 8 a useful utility has been has now been lost with the elimination of EDIT.COM. I use batch files for a variety of purposes which are much faster than mousing through a GUI, for example to archive, backup and move files using xcopy and...
Hi, Does anyone know of any tools/utilities that I can use to put a GUI front-end to my Windows scripts (batch commands)? For example, I have a batch file now that takes a password as the parameter and then executes an EXE with that password as its parameter. I'd like to have something like...
Eight Forums Android App Eight Forums IOS App Follow us on Facebook