I was infected by a virus that changed my files to .CHK. I can recover them by changing them to their original state, but the problem is, I have nearly 18GB of files impacted and it’s too time consuming to do it one-by-one. Is there a way to fix them all at once?

Mohammad Hamzani Salleh

April 27, 2013 at 7:32 am

sorry all fro the delay... im a bit busy and my sis internet just recently okay... i manage to solve this problem thank to ur help and some of then if hit the bull eye. althought my total file size is 18gb. but it just less then 10 file ext. so i rename it all to one by one ext that i remember and do it manually. so, i appreciate all of u guy help. thank you so much adn sorry again for the delay respone...

EL

March 7, 2013 at 4:37 pm

There is a free program called Ant Renamer Pro, that can rename a lot of files at once.

Mohammad Hamzani Salleh

March 7, 2013 at 4:07 am

All my file is on thumd drive. It got infected with virus and after I manage to heal it, the file got hidden in system folder created by the virus and I moved all to new folder. But then it became tricky cause all file have been change the extension to .chk after that i tried many way and got format factory to help me determind back what the real extension of that file. But since it so many file that I used to separated in each folder by type and got bulk up in one big file, it became so hard.that why I wonder if u guy know how to deal with it. It better to ask then be sorry later

Mohammad Hamzani Salleh

March 7, 2013 at 4:07 am

All my file is on thumd drive. It got infected with virus and after I manage to heal it, the file got hidden in system folder created by the virus and I moved all to new folder. But then it became tricky cause all file have been change the extension to .chk after that i tried many way and got format factory to help me determind back what the real extension of that file. But since it so many file that I used to separated in each folder by type and got bulk up in one big file, it became so hard.that why I wonder if u guy know how to deal with it. It better to ask then be sorry later

I forgot to mention earlier, but my file consist of various format that are .mp4 .flv .rar .jpg and various folder. If I do it manually, I must use format factory to define what the real attribute of that file and manualy rename the extension. So, I wonder if it have any freeware or open source that will fix or heal it in bulk.

Jan Fritsch0

March 6, 2013 at 5:17 pm

Definitely a job for a tool like TrID then.

Adding to my previous comment you probably have to use the command line version of the tool as the GUI version doesn't seem to have the option to change multiple files at once.

Basically all you need to do is download the Win32 zip file and the TRD package from the following link (at the bottom) and extract both into the same directory.http://mark0.net/soft-trid-e.html

Then open up a command prompt (Start > All Programs > Accessories ) and navigate into the directory you extracted it to e.g. "cd C:UsersnameDesktoptrid".
Then run the command with the path of the files you want to be renamedtrid.exe -ce D:directory_with_files*.*
This will automatically change all file extension to the once determined most appropriate for each file.
For more options and information I suggest reading through the page linked above.
While I haven't encountered it during my own usage you should keep in mind that there is the possibility of a false detection and therefor a wrong extension being added.

Oron Joffe

March 6, 2013 at 11:36 am

Mohammad, there are a several ways to do this. Here are three:
1. If you have only a few folders, follow Alan's advice,
2. It seems likely that you have many folders, possibly nested into other folders (18GB, crikey!). In this case you would do better to use a a file-renaming utility, such as ANT Renamer (www.antp.be/software/renamer (there are many others out there, just google "file rename" or search CNET or download.com). There are several things you should watch out for though:
a) ANT, and similar utilities, are very powerful (and dangerous), and can be complex to learn. Take your time, and do some testing on dummy folders before converting the whole lot.
b) It hardly seems possible that all your 18GB is documents of one type. You will need to figure out which files are of what type, and apply the file renaming selectively to the different groups. This could take a long time, but is important of course.
c) At least for image files, there's a way of fixing the names semi-automatically. If you rename all your image files .JPG, for example, but some of them should be .GIF, .PNG etc, you open them in IrfanView (www.irfanview.com) and it will offer to correct the extension for you. In IrfanView, you can move from one file to the next in a folder by pressing the [space] key and it opens files very quickly, so this will be a fairly quick process, although you'll still need to go from folder to folder.
3. You can create a list of all your files by going into the command line (see Allan's response) and typing the following two lines ( is the name of the folder containing all your problem files, such as "C:" or "C:UsersMohammadDocuments"):
CD
DIR /s /b *. >CMyFiles.txt

You can then open the file "MyFiles.txt" in Word or excel, sort the files by type, and the modify each line so it becomes a rename operation (if you want to do this, reply here and I'll post instructions; they're rather long and there's no point in posting them if you don't need them).

Create a folder and put all the same file types into it, by that I mean if they are all .chk and you want them all to be .dll for example.
Press Shift and right click on the folder and choose Open Command Window Here.
You will now see a Command Window with the folder directory open.
Type this command line: ren *.(current extension) *.(new extension).
Replace (current extension) with the extension you want to change and replace (new extension) with the extension you want.
For example: ren *.chk *.dll
All the files should now have the extension of your choice.
Copy them back to their original location.

nathan

April 13, 2013 at 6:51 pm

Bro I tried it but I'm not familiar with the command window, can you plz help me out

Alan Wade

April 14, 2013 at 6:22 am

Nathan if you put for example a load of jpg image files and want to rename them to txt files then the command would be:
ren *.jpg *.txt

I googled "file rename macro", a few results came up. Some are paid solutions, others seemed to be free. This is just a starting point, I'd advise you look into it more now you know what you're looking for. Authotkey (http://www.autohotkey.com/) is a free macro tool if you can't find anything. Can't imagine multiple extension renames would be easy with it, but if nothing else can be found, I'm sure it would be possible.

If you need any more help, I might find time to look into these in a bit more detail at some point.