Ver Mensaje Individual
  #2  
Antiguo 29-01-2015
Avatar de Neftali [Germán.Estévez]
Neftali [Germán.Estévez] Neftali [Germán.Estévez] is online now
[becario]
 
Registrado: jul 2004
Ubicación: Barcelona - Espańa
Posts: 18.281
Reputación: 10
Neftali [Germán.Estévez] Es un diamante en brutoNeftali [Germán.Estévez] Es un diamante en brutoNeftali [Germán.Estévez] Es un diamante en bruto
Puedes recorrer todos los formularios de la aplicación y cerrarlos uno a uno.
Si lo necesitas puedes "saltarte" el actual...

Código Delphi [-]
var
  i:integer;
  F:TForm;
begin
  // recorrer los componehtes
  for i := 0 to (Application.ComponentCount - 1) do begin
    // Nos centramos en los formularios
    if (Application.Components[i] is TForm) then begin
      F := TForm(Application.Components[i]);
      // No es este?
      if (F <> Self) then begin
        F.Close;
      end;
    end;
  end;
end;
__________________
Germán Estévez => Web/Blog
Guía de estilo, Guía alternativa
Utiliza TAG's en tus mensajes.
Contactar con el Clubdelphi

P.D: Más tiempo dedicado a la pregunta=Mejores respuestas.
Responder Con Cita