C# 点击窗口任意位置拖动
2015-04-26 01:04
399 查看
代码:
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Runtime.InteropServices; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace FreeNotes { public partial class kk : Form { public kk() { InitializeComponent(); } [DllImport("user32.dll")] public static extern bool ReleaseCapture(); [DllImport("user32.dll")] public static extern bool SendMessage(IntPtr hwnd, int wMsg, int wParam, int lParam); private void kk_MouseDown(object sender, MouseEventArgs e) { ReleaseCapture(); SendMessage(this.Handle, 0x0112, 0xF012, 0); } } }
相关文章推荐
- C#窗口任意位置拖动
- 点击窗体任意位置拖动 c#
- C#点击窗口任意位置可拖拽
- C#创建可以随意拖动的控件,拖动窗体上的任意控件到指定位置
- 两种方法实现点击窗口任意位置的拖拽
- C#在窗体中点击任意位置鼠标左键获得该点坐标
- C# WinForm窗体任意位置点击事件
- 拖动窗口任意位置移动窗口(网上找的没有整理)
- (MFC)在任意位置拖动窗口或弹出窗口菜单
- vb6源码后台点击任意窗口指定坐标XY位置,支持FLASH和一般的游戏
- C#任意位置 模拟鼠标 点击 事件 并获取 鼠标 位置 源码
- VC/MFC拖动窗口任意位置移动窗口
- mfc任意位置实现窗口拖动
- 任意位置拖动窗口
- 【转】c#可以在窗口的任一位置拖动窗口方法
- C#实现让鼠标点击任意绝对位置
- VC单击窗口任意位置都可拖动窗口
- c#winform中实现指定窗口位置鼠标点击
- vb6源码后台点击任意窗口指定坐标XY位置,支持FLASH和一般的游戏
- MFC任意位置实现窗口拖动