''This will launch Ecotect (specify correct install directory)
Dim RetVal
RetVal = Shell("C:\Program Files (x86)\Autodesk\Ecotect 2009\ECOTECT.EXE", 1)
''___________________________________________________
''and this will only launch Ecotect, if it is not already running:
Set Service = GetObject("winmgmts:")
For Each Process In Service.InstancesOf("Win32_Process")
If Process.Name = "Ecotect.exe" Then
wscript.echo "Ecotect running"
Stop
wscript.Quit
End If
Next
'wscript.echo "Ecotect not running"
Dim RetVal
RetVal = Shell("C:\Program Files (x86)\Autodesk\Ecotect 2009\ECOTECT.EXE", 1)
''___________________________________________________
I can’t remember where I found this, but I tested it for Ecotect, and it works fine. It will also work with other applications.