Autor Beitrag
Larus
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 431



BeitragVerfasst: Fr 10.03.06 23:22 
Wie kann ich alt+Tab sperren? und alt+f4 auch?
danke im voraus
JayEff
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2971

Windows Vista Ultimate
D7 Enterprise
BeitragVerfasst: Fr 10.03.06 23:31 
Nach dem ich ein bisschen gesucht hab, hab ich gefunden, dass das wohl geht, in dem man vorgaukelt, ein bildschirmschoner zu sein. Ich hab schonmal einen geschrieben. Auszug aus dem Code:
ausblenden Delphi-Quelltext
1:
    SystemParametersInfo(SPI_SCREENSAVERRUNNING, Word(true), @dummy, 0);					

statt word(true) word(false) zu schreiben, macht windows klar, dass kein Screensaver läuft. "dummy" ist eine globale variable vom Typ String.

_________________
>+++[>+++[>++++++++<-]<-]<++++[>++++[>>>+++++++<<<-]<-]<<++
[>++[>++[>>++++<<-]<-]<-]>>>>>++++++++++++++++++.+++++++.>++.-.<<.>>--.<+++++..<+.
Blackheart666
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2195

XP
D3Prof, D6Pers.
BeitragVerfasst: Fr 10.03.06 23:39 
Alt+F4

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
var erlaubt: boolean = false;

procedure TForm1.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
begin
 canclose := erlaubt;
end;

procedure TForm1.Button1Click(Sender: TObject);
begin
  erlaubt := true;
end;
JayEff
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2971

Windows Vista Ultimate
D7 Enterprise
BeitragVerfasst: Sa 11.03.06 00:13 
so sperrst du das *schließen* deiner *Form*, nicht das schließen irgenteines Programms mit der Tastenkombination Alt+F4 :/

_________________
>+++[>+++[>++++++++<-]<-]<++++[>++++[>>>+++++++<<<-]<-]<<++
[>++[>++[>>++++<<-]<-]<-]>>>>>++++++++++++++++++.+++++++.>++.-.<<.>>--.<+++++..<+.
Larus Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 431



BeitragVerfasst: Sa 11.03.06 13:43 
das ist in dem Fall ja egal... meine Form belegt den ganzen monitor und soll den PC so sperren... nur bisher ging immer nocht alt f4 und alt tab ´hoffe ich geht unter XP dank dem Bildschirmschoner effekt auch nciht mehr...
danke erstmal ich gucke gleich obs geht
Marco D.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 2750

Windows Vista
Delphi 7, Delphi 2005 PE, PHP 4 + 5 (Notepad++), Java (Eclipse), XML, XML Schema, ABAP, ABAP OO
BeitragVerfasst: Sa 11.03.06 13:46 
Ich würde auch noch überprüfen ob der Task-Manager läuft und ihn notfalls abschießen.

_________________
Pascal keeps your hand tied. C gives you enough rope to hang yourself. C++ gives you enough rope to shoot yourself in the foot
Larus Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 431



BeitragVerfasst: Sa 11.03.06 13:49 
der lässt sich nicht starten wegen dem registrie vefehl disabletskmgr oder so ähnlich^^
Hux
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 171



BeitragVerfasst: Sa 11.03.06 15:07 
@Larus

Das mit der Registry gilt nur unter Windows XP, oder?
Larus Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 431



BeitragVerfasst: Sa 11.03.06 15:46 
ja und? ich hab ja auch XP? soll ja kein öffentliches Prog werden nur für Privat... zzumindest vorerst
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5285
Erhaltene Danke: 29

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: Sa 11.03.06 15:53 
du kannst auch die killprocess funktion hooken, hab ich gemacht, wenn man dann versucht das eigene prog zu killen killt es den taskman