public static void EnumChildWindows(HWND hWndParent, string title) { System.Diagnostics.Trace.WriteLine("======================" + title + "====================="); WindowEnumDelegate del = new WindowEnumDelegate(WindowEnumProc); EnumChildWindows(hWndParent, del, 0); }//end EnumChildWindows
private static void GetWindowHandles(int procId, List <IntPtr> handles) { _handles = handles; WindowEnumDelegate pEnumWindowCallback = new WindowEnumDelegate(ProcessItem.WindowEnumProc); EnumChildWindows(IntPtr.Zero, pEnumWindowCallback, procId); }
public static extern int EnumChildWindows(IntPtr hwnd, WindowEnumDelegate del, int lParam);
// Enumerates a specified window (specified by handle) public void enumerate(IntPtr handle) { WindowEnumDelegate del = new WindowEnumDelegate(WindowEnumProc); EnumChildWindows(handle, del, 0); }
public static extern int EnumWindows(WindowEnumDelegate del, int lParam);
private static extern int EnumChildWindows(IntPtr hWnd, WindowEnumDelegate pEnumWindowCallback, int iLParam);
public static extern int EnumChildWindows( HWND hWndParent, // handle to parent window WindowEnumDelegate lpEnumFunc, // pointer to callback function int lParam // application-defined value );
public void Init() { WindowEnumDelegate del = new WindowEnumDelegate(WindowEnumProc); // call the win32 function EnumChildWindows(_axControl.Handle, del, 0); }
private bool Attach() { if (_inspectorHandle != IntPtr.Zero) { var del = new WindowEnumDelegate(WindowEnumProc); EnumChildWindows(_inspectorHandle, del, 0); if (_sendHandle != IntPtr.Zero) { return AssignHandle(); } } return false; }
private static extern bool EnumWindows(WindowEnumDelegate lpEnumFunc, int lParam);