PDA

View Full Version : scripting question (W98)



ehpjr
10-17-2003, 06:59 PM
I am trying to use the following to see if cdplayer is running

AppToCheck = "cdplayer.exe"
list = 0
For Each Process In GetObject("winmgmts:").InstancesOf("win32_process")
If Process.Name = AppToCheck Then
list = list + 1
pName = Process.Name
End If
Next
wscript.echo "there are " & list & " copies of " & pName & " running"

This works just fine in 2000 but in 98 I get an error referring to the GetObject line that says "Library not Registered"

Help

benjaminrwalker
10-23-2003, 12:23 PM
Are you using the same version of IE? I have noticed almost all versions of IE have different abilites with scripting. I hope this works.

Ben