/// <summary> /// Checks if window is maximized or not /// </summary> /// <param name="handle">window handle</param> /// <returns>true if it is</returns> public static bool IsMaximized(IntPtr handle) { var placement = new User32Interop.WINDOWPLACEMENT(); placement.length = Marshal.SizeOf(placement); User32Interop.GetWindowPlacement(handle, out placement); return placement.showCmd == ShowWindowFlags.SW_MAXIMIZE; }