English
Source / code snippets

Exe L

 

Julian
Schmidt
of these View source can detect whether a bestimmter Process runs.
i don't know whether it plainer, kürzer goes.
if so Please a Wink with the Zaunpfahl give.

let itself in the übrigen very well use in order to testing whether the Own Program carryed out becomes.
CompileMarkSeparation
Def CreateToolhelp32Snapshot(2) !"Kernel32", "CreateToolhelp32Snapshot"
Def Process32First(2) !"Kernel32", "Process32First"
Def Process32Next(2) !"Kernel32", "Process32Next"
Def CloseHandle(1) !"Kernel32", "CloseHandle"
Def GetCurrentProcessID(0) !"Kernel32", "GetCurrentProcessId"

Proc is_exists_Process

    Parameters prozess$
    Declare Entry#,err&,handle&,cpid&,ergebnis&
    Struct PROCESSENTRY32=dwSize&, cntUsage&, th32ProcessID&, th32DefaultHeapID&, th32ModuleID&, Threads&, th32ParentProcessID&, pcPriClassBase&, dwFlags&, szExeFile$(260)
    Dim Entry#,PROCESSENTRY32
    Entry#.dwSize& = SizeOf(Entry#)
    cpid&=GetCurrentProcessID()
    handle& = CreateToolhelp32Snapshot(2,0)

    If handle&

        err& = Process32First(handle&, Entry#)

        If err&

            Repeat

                err& = Process32Next(handle&, Entry#)

                If err&

                    case Entry#.szExeFile$=prozess$ : ergebnis&=1

                EndIf

            Until err& = 0

            CloseHandle(handle&)

        EndIf

    EndIf

    Dispose Entry#
    Return ergebnis&

EndProc

cls

if is_exists_Process("firefox.exe")

    print "Firefox wird ausgeführt"

else

    print "Firefox wird nicht ausgeführt"

Endif

waitinput
 
˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗
Webseite [...] 
08/08/11  
 



there's something the You always "falsch" make and so postest...

DEF-Deklarationen "gehören" not functions separate are global.
 
08/08/11  
 




Julian
Schmidt
will be it me remember
 
˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗
Webseite [...] 
08/08/11  
 



XProfan rockt if one so correctly. rockt!
 
08/08/11  
 



another hint...

instead of:
CompileMarkSeparation
if is_exists_Process("firefox.exe")

    print "Firefox wird ausgeführt"

else

    print "Firefox wird nicht ausgeführt"

/a>
simply:
CompileMarkSeparation
print "Firefox becomes "+if(is_exists_Process("firefox.exe"),"","nicht ")+"ausgeführt"

The PHP-Syntax for would:
CompileMarkSeparation
echo "Firefox becomes ".(is_exists_Process("firefox.exe")?"":"nicht ")."ausgeführt"

JavaScript:
CompileMarkSeparation
alert("Firefox becomes "+(is_exists_Process("firefox.exe")?"":"nicht ")+"ausgeführt")
 
08/08/11  
 




Dieter
Zornow
functions unfortunately not me. it'll nothing recognized. not time Firefox
 
Er ist ein Mann wie ein Baum. Sie nennen ihn Bonsai., Win 7 32 bit und Win 7 64 bit, mit XProfan X2
08/08/11  
 



two Listviews because recognized go?
 
08/08/11  
 




Julian
Schmidt
by me functions it over XProfan11, XProfanX2 terrific! Getestet from WinXP per. and Win7 Home Premium.
with IF shone it too functions to have.

lying vlt on Windoof öhhhmmmm..... windows.
 
˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗˗
Webseite [...] 
08/08/11  
 



Well as long as I do not white what Dieter really means ... ^^

Nachtrag: Ahhh... now klingelts by me.. it relating itself imho on the Ausgangsbeitrag. ^^
 
08/08/11  
 



Zum Quelltext


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

8.362 Views

Untitledvor 0 min.
Walter11/28/22
RudiB.03/08/22
Landrover05/08/21
p.specht03/01/19
More...

Themeninformationen



Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie