Delphi调用FlashWindowEx闪烁窗口源代码

...

var
  hwnd:THandle;
  F:FLASHWINFO;
begin
  ...
  if hwnd>0 then
  begin
    F.cbSize:=sizeof(FLASHWINFO);
    F.hwnd:=hwnd;
    F.dwFlags:=FLASHW_ALL or FLASHW_STOP;
    F.uCount:=4;
    F.dwTimeout:=250;
    if not IsWindowVisible(hWnd) then ShowWindow(hWnd,SW_SHOW);
    if IsIconic(hWnd) then ShowWindow(hWnd,SW_RESTORE);
    SetForegroundWindow(hWnd);
    FlashWindowEx(F);
  end;
end;

posted @ 2010-04-14 10:52  Max Woods  阅读(817)  评论(0编辑  收藏  举报