Fórum Saber quando um janela está ativa #227651
22/04/2004
0
Preciso de uma rotina que enquanto a janela estiver ativa, repita um mesmo evento, ou seja enquanto esta janela estive com o canclose = False realize a determinado evento(procedimento).
Grato
Chucky21
Curtir tópico
+ 0Posts
22/04/2004
Flayer
Gostei + 0
23/04/2004
Djjunior
Gostei + 0
23/04/2004
Chucky21
Não é exatamente o que eu quero, mas resolve o problema!
Gostei + 0
26/04/2004
Okama
Function TForm1.FORM_ATIVO( Formulario: String): Boolean; var I: integer; begin Result := False; for I := 0 to Screen.FormCount-1 do if UpTrim(Screen.Forms[i].Name) = UpTrim(Formulario) then begin Screen.Forms[I].Show; Result := True; end; end;
Use assim:
if FORM_ATIVO(´Form2´) then Timer1.Enabled := True //Aqui vai o procedimento em OnTimer else Timer1.Enabled := False;
Gostei + 0
26/04/2004
Salsa
se no caso ela nao estiver ela em foco ela sei la .. pisca
if (GetForegroundWindow <> Form1.Handle) then
begin FlashWindow(Handle, true); FlashWindow(Application.Handle, true); end
foi isso q entendi +/-
Gostei + 0
Clique aqui para fazer login e interagir na Comunidade :)