1

I am using Windows XP operating system, I have a folder with multiple files, e.g.:

  • ERHS 34334.jpg
  • ERHS 12123.jpg
  • ERHS 98484.jpg

I want to rename all those files at once as like below:

  • ERHS 34334_thumb.jpg
  • ERHS 12123_thumb.jpg
  • ERHS 98484_thumb.jpg

Existing name should not change; I want to add some unique string to the end.

2 Answers 2

0

In Command Prompt:

for %f in (ERHS*.jpg) do ren "%f" "%~nf_thumb.jpg"
0
0

In PowerShell:

Dir ERHS*.jpg | Rename-Item -NewName { $_.name -replace ".jpg", "_thumb.jpg" }

You might need to install PowerShell for Windows XP beforehand.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .