Autor Beitrag
Dabster
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 17



BeitragVerfasst: So 18.04.04 19:17 
Hallo Leute,

kann man irgendwie prüfen welche Dateien ein Programm ausführt/nutzt? Zum Beispiel welche Sounddatei von einem Audioprogramm abgespielt wird.

Danke im Vorraus
Tom
daPimP
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 54
Erhaltene Danke: 1

Win XP
D6, D7
BeitragVerfasst: Mo 19.04.04 21:18 
Frage:

Willst du nur sowas wie :

Welche Doc-Datei hat Word geladen?

oder

Welche Avi läuft gerade über MediaPlayer?

Wenn de sowas willst, musste auf andere Hilfe warten,
:cry:
aber wenn du auch wissen willst, welche DLL, VBX, DRV - Dateien dein Prog verwendet, könnte dir geholfen werden...

:lol:

_________________
watch out ... SySSnapper... coming soon
daPimP
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 54
Erhaltene Danke: 1

Win XP
D6, D7
BeitragVerfasst: Mo 19.04.04 22:11 
Habs so einfach wie möglich gehalten und alles komplizierte rausgeworfen:

ausblenden volle Höhe Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
unit Tlhelp32

procedure EXESNAP;
var SNAP, modsnap :Thandle;
    PROCS:  TprocessEntry32;
    MODULES:TModuleEntry32;
    str:string;
BEGIN
                                                 //TH32CS_SNAPProcess
 SNAP:=CreateToolhelp32Snapshot(TH32CS_SNAPall, 0);
 PROCS.dwSize  := sizeof(TProcessEntry32);
 MODULES.dwSize:= sizeof(TMOduleEntry32);

//Schleife um alle Prozesse des Systems abzuarbeiten
     if process32First(SNAP, PROCS) then
     REPEAT
      str    := ExtractFileName(PROCS.szExeFile);
      if str='[System Process]' then
       CONTINUE;
      form1.listbox1.Items.Add('*****************'+str+'**************');

    modsnap:=CreateToolhelp32Snapshot(TH32CS_SNAPMODULE, PROCS.th32ProcessID);

//ließt alle geladenen Module des Prozesses aus
      if Module32First(modsnap, MODULES) then
       repeat
        str := MODULES.szModule;

        form1.listbox1.Items.Add(str + '  '+ MODULES.szExePath + ' . . . . '+
        inttostr(MODULES.modBaseSize div 1024) + ' Kb');
      until Module32Next(modsnap,MODULES)=false;
   UNTIL process32next(snap,PROCS)=false;

CloseHandle(snap);
CloseHandle(modsnap);
end;


procedure TForm1.Button1Click(Sender: TObject);
begin
 EXESNAP;
end;


Raus kommt dann sowas:

ausblenden Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
*****************SysMaster.exe**************
SysMaster.exe  C:\Programme\Borland\PRoG\SysMaster 1.72\SysMaster.exe . . . . 840 Kb
ntdll.dll  C:\WINDOWS\System32\ntdll.dll . . . . 696 Kb
kernel32.dll  C:\WINDOWS\system32\kernel32.dll . . . . 992 Kb
user32.dll  C:\WINDOWS\system32\user32.dll . . . . 560 Kb
GDI32.dll  C:\WINDOWS\system32\GDI32.dll . . . . 256 Kb
ADVAPI32.dll  C:\WINDOWS\system32\ADVAPI32.dll . . . . 624 Kb
RPCRT4.dll  C:\WINDOWS\system32\RPCRT4.dll . . . . 536 Kb
oleaut32.dll  C:\WINDOWS\system32\oleaut32.dll . . . . 556 Kb
MSVCRT.DLL  C:\WINDOWS\system32\MSVCRT.DLL . . . . 332 Kb
OLE32.DLL  C:\WINDOWS\system32\OLE32.DLL . . . . 1156 Kb
version.dll  C:\WINDOWS\system32\version.dll . . . . 28 Kb
comctl32.dll  C:\WINDOWS\system32\comctl32.dll . . . . 556 Kb
winspool.drv  C:\WINDOWS\System32\winspool.drv . . . . 140 Kb
shell32.dll  C:\WINDOWS\system32\shell32.dll . . . . 8196 Kb
SHLWAPI.dll  C:\WINDOWS\system32\SHLWAPI.dll . . . . 404 Kb
comdlg32.dll  C:\WINDOWS\system32\comdlg32.dll . . . . 280 Kb
SynTPFcs.dll  C:\WINDOWS\System32\SynTPFcs.dll . . . . 80 Kb
Secur32.dll  C:\WINDOWS\System32\Secur32.dll . . . . 64 Kb
PSAPI.dll  C:\WINDOWS\System32\PSAPI.dll . . . . 44 Kb


Hoffe konnte dem einen oder anderen damit weiterhelfen.
Weiß noch wie ich damals an so was gesessen habe!
:lol:

_________________
watch out ... SySSnapper... coming soon
Dabster Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 17



BeitragVerfasst: Di 20.04.04 19:10 
Aha so geht das also ^^

Danke Danke