找到窗体的鼠标单击事件输入如下代码private void Form1_MouseClick(object sender, MouseEventArgs e) { Point p = e.Location; MessageBox.Show(p.ToString()); }