Ver Mensaje Individual
  #8  
Antiguo 05-11-2005
Avatar de dec
dec dec is offline
Moderador
 
Registrado: dic 2004
Ubicación: Alcobendas, Madrid, España
Posts: 13.109
Reputación: 34
dec Tiene un aura espectaculardec Tiene un aura espectacular
Hola,

Se agradece la sugerencia Troy, la incorporé a esto que copio aquí ahora... que más vale no lo hiciera, porque se va a ver en qué paro...

Código Delphi [-]
 procedure MsgPopup(const msg:
 string; const wait: integer);
 var
   i,max: integer;
   lbMsg:  TLabel;
   fmMsg:   TForm;
   panel:   TRect;
 begin
   fmMsg := TForm.Create(nil);
   try
     with fmMsg do
     begin
       Width  := 350;
       Height := 110;
       Color := clWhite;
       Caption:=' '+msg;
       SystemParametersInfo
       (48, 0, @panel,  0);
       Top := panel.Bottom;
       BorderStyle := bsToolWindow;
       FormStyle   :=  fsStayOnTop;
       lbMsg:=TLabel.Create(fmMsg);
       Left := panel.Right-fmMsg.Width-2;
       max :=panel.Bottom-fmMsg.Height-2;
       with lbMsg do
       begin
         Top  := 30;
         Left := 10;
         Height:=30;
         Parent  := fmMsg;
         AutoSize :=false;
         Caption  :=  msg;
         Font.Size :=  14;
         Font.Name := 'Arial';
         Font.Color  := clRed;
         Alignment:= taCenter;
         Font.Style:=[fsBold];
         Width := fmMsg.Width;
       end;
       Show;
       i := Top;
       while(i>=max)do
       begin
         Top := i;
         Dec(i,2);
         Refresh ;
       end;
     end;
   finally
     Sleep(wait);
     fmMsg.Free;;
   end;
 end;
__________________
David Esperalta
www.decsoftutils.com
Responder Con Cita