Jump to content

how would I?


Recommended Posts

how would I go about getting the short name of a program thats running?

$list = ProcessList()

$name = WinGetTitle("[CLASS:1mbKN41mjGj5D71F555c5nEGpoNQFchdMHAOMOMMa6r57m2Q0FkjdRdK]")

$exe = 'I want this to be the name of the .exe...ie. Explorer.exe (.exe of $name)'

MsgBox(0,"",$name)

for $i = 1 to $list[0][0]

if $list[$i][0] = $exe then

ProcessClose($list[$i][1])

EndIf

msgbox(0, $list[$i][0], $list[$i][1])

next

[u][font="Century Gothic"]~я α и d γ ĵ . ċ . ѕ қ ϊ и и ε я~- My Programs -auto shutdownSleep funcdisallow programs[/font][/u]
Link to comment
Share on other sites

how would I go about getting the short name of a program thats running?

$list = ProcessList()

$name = WinGetTitle("[CLASS:1mbKN41mjGj5D71F555c5nEGpoNQFchdMHAOMOMMa6r57m2Q0FkjdRdK]")

$exe = 'I want this to be the name of the .exe...ie. Explorer.exe (.exe of $name)'

MsgBox(0,"",$name)

for $i = 1 to $list[0][0]

if $list[$i][0] = $exe then

ProcessClose($list[$i][1])

EndIf

msgbox(0, $list[$i][0], $list[$i][1])

next

An example

Local $name
Local $exe = 'Explorer.exe'
$list = ProcessList()

For $i = 1 To $list[0][0] 
    If StringRight($list[$i][0],3) = "exe" Then
        
        if $list[$i][0] = $exe then MsgBox(0, "", $exe & " is running")
        
        $name &= $list[$i][0] & @CRLF
    EndIf   
Next
MsgBox(0, "", $name)
Link to comment
Share on other sites

An example

Local $name
Local $exe = 'Explorer.exe'
$list = ProcessList()

For $i = 1 To $list[0][0] 
    If StringRight($list[$i][0],3) = "exe" Then
        
        if $list[$i][0] = $exe then MsgBox(0, "", $exe & " is running")
        
        $name &= $list[$i][0] & @CRLF
    EndIf   
Next
MsgBox(0, "", $name)
I fixed it, thanks, problem was, if I didnt know the name of the .exe, muttley was a toughy :) lol
[u][font="Century Gothic"]~я α и d γ ĵ . ċ . ѕ қ ϊ и и ε я~- My Programs -auto shutdownSleep funcdisallow programs[/font][/u]
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...