Nov
21
2009
Visual foxpro: Terminate active windows application
tags: Programming, Tips & Trick, visual foxproHere is some code to terminate active windows application with visual foxpro :
oWMI = GETOBJECT(’winmgmts://’)
cQuery = “select * from win32_process where name=’calc.exe’”
oResult = oWMI.ExecQuery(cQuery)
? oResult.Count
FOR EACH oProcess IN oResult
? oProcess.Name
oProcess.Terminate(0)
NEXT



Entries (RSS)