Egg on my face
. I thought your reference to echo was explaining the output I saw in the CMD window. I had no idea it was actually interfering with the operation of the batch. I have made the change and the script is now returning errors.
@echo off
setlocal enabledelayedexpansion
for /f %%A in ('dir /s /b *.crop.jpg') do (
set folder=%%~dpA
set filename=%%~nA
set oldname=!folder!%%~nA.jpg
set newname=!filename:~0,-5!.full.jpg
REN "!oldname!" "!newname!"
)
echo Finished
Pause
I'm messing with the script and I'm getting now here simply fiddling with various parts of it. So I used some echo's and figured out the variables aren't holding the correct information. No clue how to fix that, but its a start. If you'd like to just pass on this, given I have a workable solution and I very well may just be aggravating you at this point, I completely understand. Thank you so much for your help thus far. I appreciate you taking a moment to help me learn
.
You'll notice "-=-=" appears in the Filename variable below. While the batch is in the root of the Grandma Photos directory, Grandma Photos itself is within a folder named "-=-= test dir 2 =-=-". Seems like Filename is somehow pulling a portion of that directory name instead.