just pass a file name that should be renamed to the script


set temp_file=%TEMP%./rename.txt
echo %1 > %temp_file%
notepad %temp_file%
set /p to= < %temp_file%
ren %1 %to%


This scripts demonstrates, how to get a file content into environment variable and back.

Read more: http://feeds.dzone.com/~r/dzone/snippets/~3/pU5sOhEB1f4/13223