.exe schliessen lassen?
Übersicht

JOKIOBetreff: .exe schliessen lassen? |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
Hi,
habe eine kurze frage kannman mit BB .exe'n schliessen ? ich meine mit .exe'n z.b die im Task Manager-> Prozesse zu finden sind. mfG JOKIO bitte um antwort ![]() |
||
![]() |
simi |
![]() Antworten mit Zitat ![]() |
---|---|---|
Ja, aber nicht mit BlitzBasic direkt, aber über userlib oder DLL schon.(vielleicht WinAPI???) | ||
JOKIO |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
klingt jetzt dumm aber wie mach ich das? ![]() |
||
![]() |
sbrog |
![]() Antworten mit Zitat ![]() |
---|---|---|
ne dll programmieren, die den Befehl enthält und dann von der Blitzbasic datei aufrufen | ||
JOKIO |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
mh keine ahnung davon ![]() ![]() thx schonmal für eure hilfe |
||
![]() |
simi |
![]() Antworten mit Zitat ![]() |
---|---|---|
Für was brauchst du's überhaupt?? Würde mich noch interessieren | ||
JOKIO |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
ich möchte für ein spiel (cs2d) ein kleines anti cheat tool schreiben das wenn man die exe startet die cs2daimbot.exe zum beispiel schliesst
mfG |
||
![]() |
Markus2 |
![]() Antworten mit Zitat ![]() |
---|---|---|
Hier mal nen VB6 Beispiel aber um das in BB nutzen zu können
mußte die APIs über die UserLibs einbinden . Wie das mit den Userlibs geht steht auf BlitzBasic.com oder benutze mal die Suche hier im Forum . Code: [AUSKLAPPEN] Private Const TH32CS_SNAPPROCESS As Long = 2& Private Const MAX_PATH As Integer = 260 Private Type PROCESSENTRY32 dwSize As Long cntUsage As Long th32ProcessID As Long th32DefaultHeapID As Long th32ModuleID As Long cntThreads As Long th32ParentProcessID As Long pcPriClassBase As Long dwFlags As Long szExeFile As String * MAX_PATH End Type Private Declare Function CreateToolhelpSnapshot Lib "kernel32" _ Alias "CreateToolhelp32Snapshot" _ (ByVal lFlags As Long, ByVal lProcessID As Long) As Long Private Declare Function ProcessFirst Lib "kernel32" _ Alias "Process32First" _ (ByVal hSnapShot As Long, uProcess As PROCESSENTRY32) As Long Private Declare Function ProcessNext Lib "kernel32" _ Alias "Process32Next" _ (ByVal hSnapShot As Long, uProcess As PROCESSENTRY32) As Long Private Declare Sub CloseHandle Lib "kernel32" _ (ByVal hPass As Long) Private Declare Function OpenProcess Lib "kernel32" (ByVal dwDesiredAccess As Long, ByVal bInheritHandle As Long, ByVal dwProcessId As Long) As Long Private Declare Function GetExitCodeProcess Lib "kernel32" (ByVal hProcess As Long, lpExitCode As Long) As Long Private Declare Function TerminateProcess Lib "kernel32" (ByVal hProcess As Long, ByVal uExitCode As Long) As Long 'Private Declare Function CloseHandle Lib "kernel32" (ByVal hObject As Long) As Long Dim Procs() As PROCESSENTRY32 Dim NOP% Private Sub List1_Click() Dim i, a&, EC& Dim Task$ Dim ProcessID, hProcess As Long Task = Procs(List1.ListIndex).szExeFile If MsgBox("Wollen Sie folgendes Programm wirklich beenden ?" & vbCrLf & Task, vbYesNo, "Achtung !") = vbNo Then Exit Sub ProcessID = Procs(List1.ListIndex).th32ProcessID hProcess = OpenProcess(&H1, 1, ProcessID) a = GetExitCodeProcess(hProcess, EC) a = TerminateProcess(hProcess, EC) CloseHandle hProcess Auflisten End Sub Private Sub Auflisten() Dim hSnapShot As Long Dim uProcess As PROCESSENTRY32 Dim r As Long ReDim Procs(0) List1.Clear hSnapShot = CreateToolhelpSnapshot(TH32CS_SNAPPROCESS, 0&) If hSnapShot = 0 Then Exit Sub uProcess.dwSize = Len(uProcess) r = ProcessFirst(hSnapShot, uProcess) Dim t As String Do While r t$ = ztrim(uProcess.szExeFile) List1.AddItem t$ r = ProcessNext(hSnapShot, uProcess) NOP = NOP + 1 ReDim Preserve Procs(NOP) Procs(NOP).szExeFile = uProcess.szExeFile Procs(NOP).cntThreads = uProcess.cntThreads Procs(NOP).th32ProcessID = uProcess.th32ProcessID Procs(NOP).th32ParentProcessID = uProcess.th32ParentProcessID Loop Call CloseHandle(hSnapShot) End Sub Private Function ztrim(ByVal z As String) As String Dim x1 As Long x1 = InStr(z, vbNullChar) If x1 > 1 Then z = Mid$(z, 1, x1 - 1) End If If x1 = 1 Then z = "" End If ztrim = z End Function |
||
![]() |
Ted |
![]() Antworten mit Zitat ![]() |
---|---|---|
So ein langer code, um nur eine .exe zu beenden? | ||
visit www.cs2d.de & www.proeight-software.de.vu |
.:_]TRaSh |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
hehe, ist halt kein BB ![]() |
||
[20:17] IMurDOOM: hm irgendwie is die mitte des viehs kaputt
[20:17] TRaSh: ein bisschen [20:18] DarkAngel: es tut mir irgend wie leid |
![]() |
theBlade |
![]() Antworten mit Zitat ![]() |
---|---|---|
JOKIO hat Folgendes geschrieben: ich möchte für ein spiel (cs2d) ein kleines anti cheat tool schreiben das wenn man die exe startet die cs2daimbot.exe zum beispiel schliesst
mfG naja dann benennt man das programm in cs2dlala.exe um und dein programm ist ausgetrickst ![]() schöne idee, aber leider nicht sonderlich effektiv |
||
"Ich bin wie ich bin. Die einen kennen mich, die anderen können mich." (Dr. Konrad Adenauer)
UTFSB -> (use the fuckin "suchen"-button) User posted image <- link -.- |
JOKIO |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
theBlade hat Folgendes geschrieben: naja dann benennt man das programm in cs2dlala.exe um und dein programm ist ausgetrickst ![]() schöne idee, aber leider nicht sonderlich effektiv ja stimmt aber sie wissen ja nicht wie es funktioniert wenn es in die Counterstrike.exe eingebunden wird thx an alle für die hilfe =) |
||
x.Force |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
ich fände es besser wenn das aufm system gefunden wird, das irgendwie das spiel den dienst verweigert *g* | ||
AMD Athlon XP 2000+ | 1024mb DDR-Ram | Asus Radeon 9600XT | BENQ FP757 17°Zoll TFT Was kümmert mich mein Geschwätz von gestern? (Konrad Adenauer) -.- |
JOKIO |
![]() Antworten mit Zitat ![]() |
|
---|---|---|
mh stimmt eigentlich ist das leichter für mich ![]() weil ich nichtmal weis was userlibs und API's sind thx nochmal an alle die mir geholfen haben ![]() |
||
Übersicht


Powered by phpBB © 2001 - 2006, phpBB Group