How Can I Determine the Version Number of an Executable File?

Hey, Scripting Guy! How can I determine the version number of an executable file?– TW Hey, TW. Well, that depends. If the file is located on the local computer, the easiest way is to use the FileSystemObject. Have a burning desire to know which version of Regedit.exe is installed on your computer? All it takes…

1

How Can I Tell if a Server has Rebooted?

Hey, Scripting Guy! Is there any way to tell whether or not a server has rebooted?– MvdM Hey, MvdM. We’re assuming that you’re performing a task and, at the end of the task, the computer is supposed to reboot. Needless to say, you want to know, “Well, did the server reboot?” How can you tell…

4

How Can I Be Notified Any Time a Service Goes Down?

Hey, Scripting Guy! How can I be notified any time a service goes down?– RN Hey, RN. As usual, there are a couple different ways you can do this, but perhaps the simplest approach is to create a script that monitors WMI events. We don’t have time to do a detailed explanation of WMI events…

0

How Can I Enumerate All the Objects in an Active Directory OU?

Hey, Scripting Guy! How can I enumerate all the objects in an Active Directory OU?– RB Hey, RB. By the way, thanks: it’s always nice to get an easy question every once in awhile! Enumerating all the objects in an OU is almost embarrassingly-simple: by default, any time you bind to an OU using ADSI…

6

How Can I Create a Folder on a Remote Computer?

Hey, Scripting Guy! Can I create a folder on a remote computer using a script?– AN Hey, AN. Life is full of mysteries. To name one, what possessed somebody to think that the world was clamoring for Clamato juice, an unholy concoction combining tomato juice and clam juice? (As long as we’re on the subject:…

7

How Can I Prompt a User for Input?

Hey, Scripting Guy! I need my script to prompt users to enter some information, like the name of the file they want to create. How do I do that?– RW, Williamsport, PA Hey, BN. The simplest – and most foolproof – way to do this is to use an InputBox; when you do that users…

6

How Can I Stop a Script Partway Through?

Hey, Scripting Guy! Is there a way to make a script stop itself if certain conditions aren’t met? Like say I’m going to copy files to a remote computer, but then the remote computer isn’t available. Can I write code that tells the script to just go ahead and quit at that point?– WK, Palo…

0

How Can I Determine the Day of the Week?

Hey, Scripting Guy! I have a script that does certain management tasks based on the day of the week. I know how get the date in a script, but how can I tell whether it’s a Monday or a Tuesday or whatever? — CT, Tallahassee, FL Hey, CT. This is actually much easier then it…

6

Can I Change the Command Window Title When Running a Script?

Hey, Scripting Guy! When I run a batch file, I can use the Title command to change the caption of the command window. Can I change the caption of the command window from within a script?– AA, Yokohama, Japan Hey, AA. Well, yes, as long as you’re willing to open up a new command window….

0

Why am I Getting an Error when Trying to Determine an IP Address?

Hey, Scripting Guy! I’m trying to determine the IP address on a computer, but I keep getting a Type Mismatch error. Do you know why? — AQ, Jacksonville, FL Hey, AQ. As a matter of fact, we do know why you’re getting a Type Mismatch error, and it’s a common problem when working with the…

0