I know there are similar posts, but non covers what I need. I need to rename all the files and sub folders of a given folder and make them uppercase. I found this post which is great but only does the files OR subfolders:
Rename all files in folder to uppercase with batch
I tried doing nested FOR with no joy. According to the manual, /R is suppose to recur through folders, but it is not doing anything. Tried /D /R with no luck either. So I was hoping to use something like below:
@echo off
setlocal enableDelayedExpansion
pushd C:\MyFolder
for /R /D %%f in (*) do (
set "filename=%%~f"
for %%A in (A B C D E F G H I J K L M N O P Q R S T U V W X Y Z) do (
set "filename=!filename:%%A=%%A!"
)
ren "%%f" "!filename!" >nul 2>&1
)
endlocal
Any ideas?