Scripting Blog [archived]

Formerly known as the "Hey, Scripting Guy!" blog

Can I Use a Script to Determine the Size of a Folder on a Remote Computer?

(image) Hey, Scripting Guy! Can I use a script to determine the size of a folder on a remote computer?-- SS(image) (image) (image) Hey, SS. Boy, you’d think you’d be able to do that, wouldn’t you? Especially if you’ve glanced through the WMI class Win32_Directory and noticed the property FileSize. Based on that, you might think...

Can I Use a Script to Rename All the Files in a Folder?

(image) Hey, Scripting Guy! Can I use a script to rename all the files in a directory and include a "pl-" prefix plus the original file name?-- JP(image) (image) (image) Hey, JP. It’s interesting how many people need to do something similar: they need to rename all the files in a given folder, either by appending the date, changing the ...

How Can I Delete All Files Older Than a Specified Date?

(image) Hey, Scripting Guy! I’d like to have a script that can search my computer for all files older than a certain date, and then automatically delete those files. Can I do that?-- GM(image) (image) (image) Hey, GM. Can you write a script that will search for and delete all the old files on your computer? You bet. Should you write a ...

How Can I Delete the Files in the Temporary Internet Files Folder?

(image) Hey, Scripting Guy! Is there a way to delete all the files in the Temporary Internet Files folder using a script?-- KR(image) (image) (image) Hey, AK. You know, prompted by your question one of the Scripting Guys (who shall remain nameless) thought to himself, “Hmmm, I wonder what’s in my Temporary Internet Files folder?” ...

How Can I Get a List of All the Files in a Folder and Its Subfolders?

(image) Hey, Scripting Guy! How can I use a script to show me all the files in a folder? And then how can I modify that script so it shows me all the files in any subfolders of that folder?-- CS(image) (image) (image) Hey, CS. Yesterday we showed everyone a script that changed all the files in a folder from read-only to read-write. We also...