بسم الله الرحمن الرحيم
اخوتي الأعزاء
هل تريدون معرفت البرامج الفتوحه او الموجوده على شريط المهام
اذاً فاليكم هذا الكود
Uses
Windows;
function EnumWindowsProc (Wnd: HWND; LParam: LPARAM): BOOL; stdcall;
Var Title : PChar;
begin
Result := True;
if (IsWindowVisible(Wnd) or IsIconic(wnd)) and
((GetWindowLong(Wnd, GWL_HWNDPARENT) = 0) or
(GetWindowLong(Wnd, GWL_HWNDPARENT) = GetDesktopWindow)) and
(GetWindowLong(Wnd, GWL_EXSTYLE) and WS_EX_TOOLWINDOW = 0) then
begin
Title:=StrAlloc(255);
GetWindowText(Wnd,Title,255);
ShowMessage(StrPas(Title));
StrDispose(Title);
end;
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
EnumWindows(@EnumWindowsProc,0);
end;