Autor Beitrag
digi_c
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1905

W98, XP
D7 PE, Lazarus, WinAVR
BeitragVerfasst: Sa 09.08.03 00:01 
Tachschön, ich will einen Scheaduler baun also Programme starten/beenden.
Starten dürfte mit Shellexecute einfach werden aber das beenden :-/
Da ich auch Programme beenden will die nur im Tray sichtbar sind dürfte Findwindow&Co flach fallen, hat da einer ne Idee?
Und ich fände es gut wenn ich das über den Pfad der Exe machen könnte
Luckie
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Sa 09.08.03 03:10 
Such mal nach Suche in: Delphi-Forum, Delphi-Library TOOLHELP32SNAPSHOT und / oder Suche in: Delphi-Forum, Delphi-Library ENUMPROCESSES.
AndyB
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 1173
Erhaltene Danke: 14


RAD Studio XE2
BeitragVerfasst: Sa 09.08.03 09:39 
Luckie hat folgendes geschrieben:
Such mal nach ToolHelp32SnapShot und / oder EnumProcesses.

Wieso so umständlich. Er kann die Programme doch einfach mit CreateProcess oder ShellExecuteEx starten und hat dann bereits das Prozesshandle, mit dem er Zugriff auf die Prozesse hat.

_________________
Ist Zeit wirklich Geld?
recall
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 449



BeitragVerfasst: So 10.08.03 14:06 
@Andy B: Ich denke mal, er will auch Programme beenden, die er nicht selber gestartet hat, oder ?
AndyB
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 1173
Erhaltene Danke: 14


RAD Studio XE2
BeitragVerfasst: So 10.08.03 14:12 
Dann versteht er was anderes unter Schedular als ich.

_________________
Ist Zeit wirklich Geld?
recall
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 449



BeitragVerfasst: So 10.08.03 14:28 
Nur weil er meinte:
Zitat:
Und ich fände es gut wenn ich das über den Pfad der Exe machen könnte
digi_c Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1905

W98, XP
D7 PE, Lazarus, WinAVR
BeitragVerfasst: Di 12.08.03 08:59 
Ich meinte damit nur dass ich die Dateien über die .EXE identifizieren will und nicht mit FindWindow oder so.
Gibt es denn irgendwo ein Bispiel mal wo gezeigt wird wie man wenn man ein Progr. über ShellExecute gestartet hat das bennden kann (oder vielleicht Tasten drücken/...) :?:
Tino
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Veteran
Beiträge: 9839
Erhaltene Danke: 45

Windows 8.1
Delphi XE4
BeitragVerfasst: Di 12.08.03 11:03 
Hallo!

Statt ShellExecute würde ich Suche in: Delphi-Forum, Delphi-Library CREATEPROCESS zum Starten von Anwendungen benutzen. Über CreateProcess bekommst du auch ein Handle. Mit diesem Handle sollte man die Anwendung wieder schließen können.

Gruß
Tino
Luckie
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Di 12.08.03 11:26 
Oder ShellexecuteEx.
AndyB
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 1173
Erhaltene Danke: 14


RAD Studio XE2
BeitragVerfasst: Di 12.08.03 13:57 
Das habe ich doch irgendwo schon mal geschrieben. :wink:
2. Antwort - hat folgendes geschrieben:
Er kann die Programme doch einfach mit CreateProcess oder ShellExecuteEx starten

_________________
Ist Zeit wirklich Geld?