Mega Code Archive

 
Categories / Delphi / Graphic
 

Creating a flashing icon

Title: Creating a flashing icon Question: How can I create a flashing icon Answer: You can call the Windows API function FlashWindow: var Flash : bool; procedure TForm1.Timer1Timer(Sender: TObject); begin FlashWindow(Form1.Handle, Flash); FlashWindow(Application.Handle, Flash); Flash := not Flash; end; procedure TForm1.FormCreate(Sender: TObject); begin Flash := False; end;