We value your feedback.
Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!
ProcessName = "notepad.exe" Set objWMI = GetObject("winmgmts:\\.\root\cimv2") Do Set colItems = objWMI.ExecQuery ("Select * from Win32_Process Where Name = '" & ProcessName & "'") wscript.sleep 1500 Loop While colItems.Count = 0 Set colProcesses = objWMI.ExecNotificationQuery ("Select * From __InstanceDeletionEvent " _ & "Within 1 Where TargetInstance ISA 'Win32_Process' And TargetInstance.Name = '" & ProcessName & "'") Do Set objProcess = colProcesses.NextEvent Set objWMIService = GetObject ("winmgmts:\\.\root\cimv2:Win32_Process") objWMIService.Create ProcessName, null, null, intProcessID msgbox "Started" Loop
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.