Quantcast
Channel: VMware Communities : Popular Discussions - VMware ThinApp: Discussion Forum
Viewing all articles
Browse latest Browse all 57744

script error onfirstparentstart

$
0
0

Hi! I'm newbie to thinpacking, and I am trying to pack firefox 3.6.8 and java 6 update 21, and for some reason on windows 7 java hangs up when used, and (random).console.exe process stays on after closing firefox. I tried to make this function to kill prior hanged processes and clean leftover files when firefox starts, works fine on it's own, but when adding this to firefox project folder, I get error like this:

 

Script Error

Source: Microsoft VBScript runtime error

Description : Object required: 'WScript'

File: (null)

Line 13, Character 0

at:

 

Here is the script:

 

Function OnFirstParentStart

 

strComputer = "."

 

Set objWMIService = GetObject("winmgmts:" _

    & "{impersonationLevel=impersonate}!
" & strComputer & "\root\cimv2")

Set colProcessList = objWMIService.ExecQuery _

    ("SELECT * FROM Win32_Process WHERE Name LIKE '%.console.exe%'")

For Each objProcess in colProcessList

    objProcess.Terminate()

Next

 

Dim objFSO, copyFile, vSystemDrive

Set WshShell = WScript.CreateObject("Wscript.Shell")

vAPPDATA = WshShell.ExpandEnvironmentStrings("%APPDATA%")

Set objFSO = CreateObject("Scripting.FileSystemObject")

objFSO.DeleteFile(vAPPDATA & "\Thinstall\Mozilla Firefox\SKEL\*.*")

 

 

End Function

 

 

Please help....


Viewing all articles
Browse latest Browse all 57744

Trending Articles