@msdn=http://search.microsoft.com/search/results.aspx?qu=$$$ @pinvoke=http://pinvoke.net/$$$.htm Summary: The WindowFromPoint API !!!!C# Signature: [DllImport("user32.dll")] static extern IntPtr WindowFromPoint(System.Drawing.Point p); !!!!VB.NET Signature: <DllImport("user32.dll")> _ Private Shared Function WindowFromPoint(ByVal p As Point) As IntPtr End Function !!!!Oxygene.NET Signature: [DllImport("user32.dll")] class method WindowFromPoint(aPoint: System.Drawing.Point): IntPtr; external; !!!!Notes: The WindowFromPoint function retrieves a handle to the window that contains the specified point. Make sure not to use System.Windows.Point. !!!!Tips & Tricks: Please add some! !!!!Sample Code: [DllImport("user32.dll")] static extern bool GetCursorPos(out Point lpPoint); [DllImport("user32.dll")] static extern bool SetWindowText(IntPtr hWnd, string lpString); Point p; if (GetCursorPos(out p)) { IntPtr hWnd = WindowFromPoint(p); if (hWnd != IntPtr.Zero) SetWindowText(hWnd, "Window Found"); } !!!!Alternative Managed API: Do you know one? Please contribute it! !!!!Tips & Tricks: Please add some! !!!!Alternative Managed API: Do you know one? Please contribute it! Documentation: https://msdn.microsoft.com/en-us/library/ms633558.aspx
Edit user32.WindowFrom...
You do not have permission to change this page. If you feel this is in error, please send feedback with the contact link on the main page.