Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
I’ve searched the forums on this site & couldn’t find anything conclusive. I need a DOS batch command similar to the one below to add a '.tif' extension to multiple files that have a specific pattern in their extension.
The DOS batch command line: for %%i in (*.????????) do ren %%i %%i.tif
For example, rename *.20080902 to *.20080902.tif in the same directory as the batch file.
The only problem is that the above script renames all files in the directory (including the batch file 'ren2tif.bat').
The script needs to SKIP files that DO NOT have the 8-digit numeric format (i.e., *.yyyymmdd) in the extension.
Name: Wahine Date: August 18, 2009 at 00:44:32 Pacific
Reply:
Try using a bit more detail in the extension e.g. *.2008????
0
Response Number 2
Name: fengineer Date: August 18, 2009 at 17:04:40 Pacific
Reply:
Thanks,
That worked. The solution looks so obvious now.
I changed the the batch file as follows: for %%i in (*.20??????) do ren %%i %%i.tif
This will rename any file produced this century. These are simply TIF images that get churned out by a CAD program & uploaded to a unix server. I needed this script to work for Windows so we can review/print drawings before uploading them to our unix server. Some projects may over a hundred drawings so renaming them one by one is not practical!
Summary: I have a certain file under C:\Documents and Settings\Owner\Local Settings\Temporary Internet Files\Content.IE5\O942SDWE title "1O4-4583528-8646333[1]." with no extension. When I click on it, an erro...
Summary: I have a file (123.jpg) in a folder (abc) and i need to rename the file with the folder name (abc.jpg). Is this possible with a batch file assigned to right button of mouse? 1234567890 ...
Summary: My dad accidently turned the power bar off to my computer. Some folders came back with funky extensions (Norton fixed it). But then I noticed there were some large files with no extensions and realize...