Autor Beitrag
elundril
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3747
Erhaltene Danke: 123

Windows Vista, Ubuntu
Delphi 7 PE "Codename: Aurora", Eclipse Ganymede
BeitragVerfasst: Di 16.05.06 16:51 
Ich habe da mal so ein ähh Formular. und ähhh ich will das es immer im Vordergrund bleibt. nur ähhh das ähh tut es nicht so ganz. ich hab schon den formstyle auf fsStay on top gesetzt nur es will noch immer nicht!!!
ich bin verzweifelt!
was soll ich nur tun???

^^

_________________
This Signature-Space is intentionally left blank.
Bei Beschwerden, bitte den Beschwerdebutton (gekennzeichnet mit PN) verwenden.
azubi_20
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 593

WinXP SP2, Ubuntu 8.4
D7 Enterp., D2005 Prof., Java (Eclipse 3.4.0)
BeitragVerfasst: Di 16.05.06 17:25 
komisch...
eigentlich müsste es so funktionieren.
user profile iconelundril hat folgendes geschrieben:
nur ähhh das ähh tut es nicht so ganz.

was tut es denn ?
elundril Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3747
Erhaltene Danke: 123

Windows Vista, Ubuntu
Delphi 7 PE "Codename: Aurora", Eclipse Ganymede
BeitragVerfasst: Di 16.05.06 17:27 
wenn ich zb Word aufruf dann ist das Programm hinter dem Word. Mein Vater (hauptberuflicher VB programmierer) hat mir gezwitschert das es da ne api funktion gibt! nur möcht ich wissen wie sie heißt und wie man sie aufruft!

_________________
This Signature-Space is intentionally left blank.
Bei Beschwerden, bitte den Beschwerdebutton (gekennzeichnet mit PN) verwenden.
azubi_20
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 593

WinXP SP2, Ubuntu 8.4
D7 Enterp., D2005 Prof., Java (Eclipse 3.4.0)
BeitragVerfasst: Di 16.05.06 17:46 
user profile iconelundril hat folgendes geschrieben:
wenn ich zb Word aufruf dann ist das Programm hinter dem Word.

kann ich leider nicht nachvollziehen... Bei mir steht di Form immer im Vordergrund, egal ob ich word oder was anderes aufmache :roll:
magnitudo
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 31

WIN 8.1

BeitragVerfasst: Di 16.05.06 17:52 
user profile iconelundril hat folgendes geschrieben:
wenn ich zb Word aufruf dann ist das Programm hinter dem Word. Mein Vater (hauptberuflicher VB programmierer) hat mir gezwitschert das es da ne api funktion gibt! nur möcht ich wissen wie sie heißt und wie man sie aufruft!


Hallo elundril,

stimmt ! Das Phänomen kenne ich. Hab in meiner Anwendung unter Settings auch ein Häkchen eingebaut mit dem der User die Anwendung auf OnTop stellen kann, wenn er will. Dies funktioniert aber leider nicht perfekt ! Meistens ist die Anwendung dann zu Beginn tatsächlich OnTop. Wird aber währenddessen Word oder eine andere Anwendung gestartet, dann verliert meine OnTop gestelle Aplikation sporadisch (ich weis leider nicht wie und wann das passiert) sein OnTop.
Ich muss dann das Häkchen aus/an - Klicken damit OnTop wieder funktioniert ! Seltsam oder ?
Anscheinend verliert dieses OnTop-Flag, bedingt durch andere parallel laufende Anwendungen immer wieder seinen Wert.

Vielleicht finden wir ja noch die Lösung

Viele Grüße
Thomas
elundril Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3747
Erhaltene Danke: 123

Windows Vista, Ubuntu
Delphi 7 PE "Codename: Aurora", Eclipse Ganymede
BeitragVerfasst: Mi 17.05.06 19:54 
viel leicht immer wenn es den Fokus Verliert ein ontop off und gleich wieder ein ontop on?!?

_________________
This Signature-Space is intentionally left blank.
Bei Beschwerden, bitte den Beschwerdebutton (gekennzeichnet mit PN) verwenden.
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: Mi 17.05.06 20:01 
Tut's auch ein Timer mit einem regelmäßigem application.bringtofront ?

_________________
Pascal keeps your hand tied. C gives you enough rope to hang yourself. C++ gives you enough rope to shoot yourself in the foot
elundril Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3747
Erhaltene Danke: 123

Windows Vista, Ubuntu
Delphi 7 PE "Codename: Aurora", Eclipse Ganymede
BeitragVerfasst: Mi 17.05.06 20:04 
timer frisst resoucen!!!

_________________
This Signature-Space is intentionally left blank.
Bei Beschwerden, bitte den Beschwerdebutton (gekennzeichnet mit PN) verwenden.
LeastCosterXP
Hält's aus hier
Beiträge: 5



BeitragVerfasst: Fr 19.05.06 13:55 
Titel: StayOnTop
Wenn du das FormStyle auf fsStayOnTop stellst, dann gilt das nur Programmweit, also dein Fenster ist über deinen eigenen Programmfenstern.
Systemweit kannst du es folgendermaßen realsieren:
Du bringst die Komponente "TApplicationEvents" auf dein Form (findest du glaube ich unter 'System'). Diese Komponente hat ein Event 'OnDeactivate'. Und in diesem Event machst Du einfach ein Form1.BringToFront;

Fertig :))

Grüße jesus :)
elundril Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3747
Erhaltene Danke: 123

Windows Vista, Ubuntu
Delphi 7 PE "Codename: Aurora", Eclipse Ganymede
BeitragVerfasst: Sa 20.05.06 19:53 
^^
danke aber ich habs schon hinbekommen!! plötzlich funktionierts mit stay on top!!
jaja die Technik is a Hund!!!

mfg el

_________________
This Signature-Space is intentionally left blank.
Bei Beschwerden, bitte den Beschwerdebutton (gekennzeichnet mit PN) verwenden.
Coder
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 1383
Erhaltene Danke: 1

WinXP
D2005 PE
BeitragVerfasst: Sa 20.05.06 20:08 
Soweit ich weis wird die Anwendung nur über andere Programme gelegt wenn das Hauptformular fsStay on top ist.
elundril Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3747
Erhaltene Danke: 123

Windows Vista, Ubuntu
Delphi 7 PE "Codename: Aurora", Eclipse Ganymede
BeitragVerfasst: Sa 20.05.06 20:12 
kann sein! auf jeden Fall funkts jetzt bei mir!! ich schau aber trotzdem mal nach!

_________________
This Signature-Space is intentionally left blank.
Bei Beschwerden, bitte den Beschwerdebutton (gekennzeichnet mit PN) verwenden.
JayEff
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2971

Windows Vista Ultimate
D7 Enterprise
BeitragVerfasst: So 21.05.06 01:17 
user profile iconelundril hat folgendes geschrieben:
timer frisst resoucen!!!

Tut er nicht. Ob da nun 100000000000000000000001 Message pro sekunde verarbeitet wird, oder 100000000000000000000000 ... egal.

_________________
>+++[>+++[>++++++++<-]<-]<++++[>++++[>>>+++++++<<<-]<-]<<++
[>++[>++[>>++++<<-]<-]<-]>>>>>++++++++++++++++++.+++++++.>++.-.<<.>>--.<+++++..<+.
Jakob Schöttl
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 929
Erhaltene Danke: 1


Delphi 7 Professional
BeitragVerfasst: Mo 22.05.06 12:24 
Es geht auch so:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
procedure ImmerImVordergrund(b: Boolean; Form: TForm);
begin
 With Form do begin
  if b then begin
    {Fenster nach vorne setzen:}
    SetWindowPos(Handle,
    HWND_TOPMOST,
    Left,Top, Width,Height,
    SWP_NOACTIVATE or SWP_NOMOVE or SWP_NOSIZE);
  end else begin
    {..und wieder zurück:}
    SetWindowPos(Handle,
    HWND_NOTOPMOST,
    Left, Top, Width,Height,
    SWP_NOACTIVATE or SWP_NOMOVE or SWP_NOSIZE);
  end;
 end;
end;


Meine Quelle war mal wieder www.delphi-fundgrube.de