[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Batch Script:  Add .jpg to all files in a folder

Posted on 2012-08-18
4
Medium Priority
?
1,030 Views
Last Modified: 2012-08-18
Hi All,


I'd like to add .jpg to the end of every file in a folder.

I guess it would be something like;

dir | rename %1 %1.jpg
0
Comment
Question by:detox1978
  • 2
4 Comments
 
LVL 59

Accepted Solution

by:
Bill Prew earned 2000 total points
ID: 38307684
If the files have no extension currently then this should work:

ren *. *.jpg

~bp
0
 
LVL 2

Author Comment

by:detox1978
ID: 38307688
Thanks,

ren *.* *.jpg

worked.
0
 
LVL 11

Expert Comment

by:paultomasi
ID: 38307783
Wow! I wish earning money instead of points was THAT easy !!
0
 
LVL 59

Expert Comment

by:Bill Prew
ID: 38307817
Great, glad it was as simple as that, thanks for the feedback.

~bp
0

Featured Post

Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
Originally, this post was published on Monitis Blog, you can check it here . In business circles, we sometimes hear that today is the “age of the customer.” And so it is. Thanks to the enormous advances over the past few years in consumer techno…
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses
Course of the Month18 days, 2 hours left to enroll

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question