Replace all files name inside specific floder

step 1 : open notepad and paste following code

@echo off
setlocal enabledelayedexpansion
for %%j in (*.*) do (
set filename=%%~nj
set filename=!filename:.=_!
set filename=!filename: =_!
if not "!filename!"=="%%~nj" ren "%%j" "!filename!%%~xj"
)

then Save as replacefiles.bat

now copy and paste  replacefiles.bat file inside the specific floder which you want to rename the files. Run  replacefiles.bat file

Note : replacefiles.bat  needs to be executed in the folder containing the files 

Ref : http://www.computing.net/answers/programming/batch-script-to-replace-filenames-h/16301.html
Replace all files name inside specific floder Replace all files name inside specific floder Reviewed by (C#) Csharp examples on 11:17 PM Rating: 5

No comments:

Facebook

Powered by Blogger.