Expiring Today—Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

blinking applications in task bar

Posted on 2004-08-03
4
Medium Priority
?
272 Views
Last Modified: 2010-04-04
When receiving a message from socket connection I need to open myform (minimized) and blink my application in task bar...

 How may I blink my application in task bar?

0
Comment
Question by:faustomen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 11

Expert Comment

by:Jase-Coder
ID: 11705584
hi there is an Api and to inmplement it do:

flashwindow(form1.handle, true);
0
 
LVL 12

Accepted Solution

by:
esoftbg earned 1000 total points
ID: 11706025
program Q_21080519;

uses
  Forms,
  Windows,
  Unit1 in 'Unit1.pas' {Form1};

{$R *.res}

begin
  Application.Initialize;
  Application.ShowMainForm := False;
  Application.CreateForm(TForm1, Form1);
  ShowWindow(Application.MainForm.Handle, SW_HIDE);
  ShowWindow(Application.Handle, SW_MINIMIZE);
  Application.Run;
end.

//........

unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, Buttons, ExtCtrls;

type
  TForm1 = class(TForm)
    SpeedButtonStopBlink: TSpeedButton;
    OpenDialog: TOpenDialog;
    Timer: TTimer;
    SpeedButtonBlink: TSpeedButton;
    procedure FormCreate(Sender: TObject);
    procedure TimerTimer(Sender: TObject);
    procedure SpeedButtonStopBlinkClick(Sender: TObject);
    procedure SpeedButtonBlinkClick(Sender: TObject);
  private   { Private declarations }
  public    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.FormCreate(Sender: TObject);
begin
  Timer.Enabled := True;
end;

procedure TForm1.TimerTimer(Sender: TObject);
begin
  FlashWindow(Application.Handle, True);
end;

procedure TForm1.SpeedButtonBlinkClick(Sender: TObject);
begin
  Timer.Enabled := True;
end;

procedure TForm1.SpeedButtonStopBlinkClick(Sender: TObject);
begin
  Timer.Enabled := False;
end;

end.
0
 
LVL 2

Expert Comment

by:DarkCore_
ID: 11712867
Just a notation, if you look into the first comment of esoftbg, is the correct answer, but alert, FlashWindowEx is only implemented in Windows 98 SE or higher. If your program needs to run on a Windows 95, then you must use the timer.

Edu
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
This course is ideal for IT System Administrators working with VMware vSphere and its associated products in their company infrastructure. This course teaches you how to install and maintain this virtualization technology to store data, prevent vuln…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
Suggested Courses

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question