Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Sonstige Fragen zu Delphi (https://www.delphipraxis.net/19-sonstige-fragen-zu-delphi/)
-   -   Delphi Problem mit SetFocus (https://www.delphipraxis.net/129519-problem-mit-setfocus.html)

AlexII 20. Feb 2009 12:28


Problem mit SetFocus
 
Hallo,

hab folgendes Problem: hab auf meinem Form paar Images und eine ComboBox. Wenn ich das Prog starte hat die ComboBox den Focus, was nicht so gut aussieht. Wie entferne ich diesen Focus?

DeddyH 20. Feb 2009 12:30

Re: Problem mit SetFocus
 
Pack doch die Images auf ein Panel und gib dem dann den Fokus.

AlexII 20. Feb 2009 12:44

Re: Problem mit SetFocus
 
Gibt's vllt eine andere Möglichkeit? Hab keine Lust das halbe Programm umbauen, hab da nämlich 18 Images.

Luckie 20. Feb 2009 12:45

Re: Problem mit SetFocus
 
Setz die Tabreihenfolge entsprechend, so das die Combobox nicht mehr als erstes in der Tabreihenfolge steht.

AlexII 20. Feb 2009 12:55

Re: Problem mit SetFocus
 
Hab ich gemacht, ändert sich aber gar.nix; :gruebel:
Ich weiß klingt komisch, ist aber so.

PS: Panel ist bei mir versteckt. Aber auch nicht versteckt funkt nicht. :gruebel:

AlexII 20. Feb 2009 13:01

Re: Problem mit SetFocus
 
Hab das jetzt so gelöst:

Delphi-Quellcode:
procedure TForm1.FormShow(Sender: TObject);
begin
Panel1.Visible:=True;
Panel1.SetFocus;
Panel1.Visible:=False;
end;
Jetzt klappt's :thumb:

toms 20. Feb 2009 13:05

Re: Problem mit SetFocus
 
Hallo

Setze TabStop der Combobox auf False. Dann erhält sie anfangs nicht mehr den Fokus.

AlexII 20. Feb 2009 13:12

Re: Problem mit SetFocus
 
Zitat:

Zitat von toms
Hallo

Setze TabStop der Combobox auf False. Dann erhält sie anfangs nicht mehr den Fokus.

Wow danke, wo warst du früher... :thumb:


Alle Zeitangaben in WEZ +1. Es ist jetzt 07:58 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz