Scripting Blog [archived]

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

How Can I Replace a Local File with a Newer Version Found on a File Server?

(image) Hey, Scripting Guy! How can I compare the modification date of the local file with its counterpart on a file server and then, if the local file is older, replace it with the version on the file server?-- DC(image) (image) (image) Hey, DC. Let’s see, you want to take something old and replace it with something new. For some reason...

How Can I List All the Items in the Run Key in the Registry?

(image) Hey, Scripting Guy! How can I list all the items in the Run key in the registry?-- JW(image) (image) (image) Hey, JW. How can you list all the items in the Run key in the registry? Well, to be honest, we’re not going to tell you. Nope, sorry. Not because we don’t like you, but because we think we have a better answer for you. (...

How Can I Specify the Computers a User Can Use to Log On to the Domain?

(image) Hey, Scripting Guy! How can I configure a user account so that the user can only log on to the domain using specific computers?-- RB(image) (image) (image) Hey, RB. You know, at one point we had some really good solutions for you; unfortunately, Microsoft’s legal department said no to every single one of them. In their view, “...

How Can I Determine Which Account a Script is Running Under?

(image) Hey, Scripting Guy! How can I determine which account a script is running under?-- KW(image) (image) (image) Hey, KW. You know, it’s been awhile since we started off a column with a bunch of excuses, and that’s been hard on us: after all, making excuses is what we Scripting Guys do best. With that in mind, then, let’s start ...

How Can I Determine the Last Row in an Excel Spreadsheet?

(image) Hey, Scripting Guy! How can I determine the last row in an Excel spreadsheet? I can’t append data to the file unless I know which row to start with.-- TGW(image) (image) (image) Hey, TGW. You know, this is the kind of thing that separates the Scripting Guys from the rest of the world. Most people would do the same thing you’re ...