processlist Windows property
Return to Introduction  Previous page  Next page
Applies to
acProcess object.  

Declaration
property Windows: Array of hWnd; // read-only!  

Description
The Windows property is the list of all windows handles which belongs to the process.  
 
To enumerate all windows programmatically you can use following code example:  
  if High(Windows) >= 0 then // if application have windows  
   // Return the window title of the first visible window  
   // whose title is non-empty  
   for I := 0 to High(Windows) do  
    if IsWindowVisible(Windows[I]) then  
     begin  
      Result := acUtils.GetWindowTitle(Windows[I]); // retrieve the title of Window by handle  
      if Result <> '' then Exit;  
     end;  
 
tip To determinate the title of first visible window of the process — read WindowTitle property.  

See also
WindowTitle property.