D:\@@>dir c:\Windows\System32\query.exe
Volume in drive C is System Reserved Serial number is 9a68:56ae
Directory of C:\Windows\System32\query.exe
12.04.2018 12:20 16 896 query.exe
16 896 bytes in 1 file and 0 dirs 20 480 bytes allocated
18 140 975 104 bytes free
D:\@@>c:\Windows\System32\query.exe
Invalid parameter(s)
QUERY { PROCESS | SESSION | TERMSERVER | USER }
PROCEDURE Main()
local cRUN
cRUN := "c:\Windows\System32\query.exe"
?cRUN, "exists:", hb_vfexists( cRUN ), file( cRUN ), hb_FileExists( cRUN ) //.f., .f., .f.
if hb_processRun( cRUN ) == -1
?"Cannot run " + cRun
endif
?
cRUN := "c:\Windows\System32\qprocess.exe"
?cRUN, "exists:", hb_vfexists( cRUN ), file( cRUN ), hb_FileExists( cRUN ) //.f., .f., .f.
if hb_processRun( cRUN ) == -1
?"Cannot run " + cRun
endif
?
cRUN := "c:\Windows\System32\cmd.exe"
?cRUN, "exists:", hb_vfexists( cRUN ), file( cRUN ), hb_FileExists( cRUN ), "New shell will start. type EXIT <ENTER> to return." //.t., .t., .t.
if hb_processRun( cRUN ) == -1
?"Cannot run " + cRun
endif
?"TEST END"
wait
returnD:\@@>test
c:\Windows\System32\query.exe exists: .F. .F. .F.
Cannot run c:\Windows\System32\query.exe
c:\Windows\System32\qprocess.exe exists: .F. .F. .F.
Cannot run c:\Windows\System32\qprocess.exe
c:\Windows\System32\cmd.exe exists: .T. .T. .T. New shell will start. type EXIT <ENTER> to return.Microsoft Windows [Version 10.0.17134.228]
(c) 2018 Microsoft Corporation. All rights reserved.
D:\@@>exit