How Can I Tell Which Service Packs Have Been Installed on a Computer?

Hey, Scripting Guy! How can I tell which service packs have been installed on my computers?– FR Hey, FR. That’s a very good question; as you know better than we do, in this day and age it’s really important to make sure all your computers have the latest service pack, the latest hot fixes, and…


How Can I Get a List of the Devices That Aren’t Working?

Hey, Scripting Guy! In Device Manager, any time a device isn’t working that device is marked with a yellow exclamation mark. How can I use a script to get a list of the devices that aren’t working?– OL Hey, OL. Sometimes in baseball a batter absolutely hammers one, but the ball takes a lucky bounce…


How Can I Terminate a Process with a Specific PID?

Hey, Scripting Guy! If I have the PID, is there a way to kill a process using a script?– JV Hey, JV. You bet there is. For those of you who aren’t familiar with the acronym, PID is short for Process Identifier, a unique ID number assigned to a process when it gets created. (Well,…


How Can I Get a List of Exchange Servers Assigned to My Users?

Hey, Scripting Guy! How do I get a list of the Exchange servers (msExchHomeServerName) assigned to the users in an OU?– BG Hey, BG. As you probably already figured out, you have two issues: you need to get a list of all the users in an OU, and then you need to figure out which…


How Can I Display Multiple Lines of Output in a Web Page?

Hey, Scripting Guy! How do I get multiple lines of output in a Web page using the Document.Body.InnerHTML property? I can only get one line of output on my page.– CM Hey, CM. Sounds like you’re creating an instance of Internet Explorer and trying to display script output in it. And we’re willing to bet…


How Can I Manage Scheduled Tasks Using Scripts?

Hey, Scripting Guy! Is there an easy way to manage scheduled tasks using scripts?– RC Hey, RC. You just had to ask that question, didn’t you? To be honest, this is not one of scripting’s strong points, and you might be more confused after hearing the answer than you were before asking the question. But…


How Can I Determine if a Computer is a Laptop or a Desktop Machine?

Hey, Scripting Guy! Is there any way to use WMI to determine whether a computer is a laptop or a desktop machine?– CB Hey, CB. You bet there is, although if you didn’t know that we have no idea how you’d figure it out on your own. It turns out there’s a goofy little WMI…


How Can I Tell if a Computer Has a DVD Drive Installed?

Hey, Scripting Guy! How can I tell if a computer has a DVD drive installed?– GC Hey, GC. No doubt you’re hoping we’ll say something like, “Why, you just use the Win32_DVD class, of course.” Unfortunately, though, we can’t say that; that’s because there is no Win32_DVD class, or any class devoted to DVD drives….


How Do I Bind to a User Account in a Sub-OU?

Hey, Scripting Guy! How do I bind to a user account when the user is in a sub-OU? Code like this doesn’t work: LDAP://CN=Ken Meyer, OU=NA\Human Resources, DC=fabrikam, dc=com.– RD Hey, RD. The past few days we’ve done some lengthy answers to questions, so we decided to be a little lazy today (hey, it is…


How Do I Get Rid of Extraneous Spaces in a String?

I know that I can use the Split command to separate a sentence like this – VBScript is fun! – into an array of individual words. However, what happens if I have a sentence like this: VBScript is fun! I can’t use a blank space as the delimiter because I might have lots of blank…