Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6014123
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T02:38:47+00:00 2026-05-23T02:38:47+00:00

I have a situation where we have several thousand image files that have become

  • 0

I have a situation where we have several thousand image files that have become corrupted on our server (Windows 2008 R2 x64). I have a working image file that I want to replace the corrupt files with. The files must retain the same name and path (size, timestamps, etc do not matter).

So the basic idea would be to replace each corrupt image file with the working file.

I do not write code, only the occasional windows batch file.

Should I use VB or PowerShell (or something else) for this? What will the script look like for this?

I apologize in advance if this question is too basic for stackoverflow.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T02:38:48+00:00Added an answer on May 23, 2026 at 2:38 am

    You don’t really need a batch file,

    try looking at the for command

    e.g.

    FOR /R %f in (*.jpg) DO copy newfile.jpg “%f”

    This should do a recursive search and copy newfile.jpg over the jpg’s it finds.

    It all boils down to how you are identifying the broken jpgs.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Our Situation: We have several webservers behind a loabalancer (Astaro Security Gateway). On the
I have a situation where I have several root applications that will reference the
Please read the entire question. I have a unique situation with several constraints that
I have a situation where I want to use several server side controls, which
The Situation I have a WPF program that I want to print several documents
Situation: We have several small icons on our Magento Product page. After clicking one,
I have a situation where I have a class that is referenced by several
We currently have a situation where several tests are failing. Someone is working on
We have this recurring situation where several times a week our application stops responding.
I have a problem with the following situation: several commits are pushed to a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.