public static extern bool SetWindowPos(IntPtr hWnd, IntPtr hWndInsertAfter, int X, int Y, int cx, int cy, [MarshalAs(UnmanagedType.U4)] NativeMethods.WindowPosition uFlags);
public static void SetWindowPos(IntPtr hWnd, IntPtr hWndInsertAfter, int x, int y, int cx, int cy, NativeMethods.WindowPosition uFlags) { ThrowLastError(!UnsafeNativeMethods.SetWindowPos(hWnd, hWndInsertAfter, x, y, cx, cy, uFlags)); }