C# 如何设置窗体的光标位置?

C# 如何设置窗体的光标位置?,c#,C#,设置窗体上光标位置的代码: SetCursorPos(webControl1.PointToClient(Cursor.Position).X, webControl1.PointToClient(Cursor.Position).Y); Thread.Sleep(100); mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0); mouse_event(MOUSEEVENTF_LEFT

设置窗体上光标位置的代码:

SetCursorPos(webControl1.PointToClient(Cursor.Position).X, webControl1.PointToClient(Cursor.Position).Y);
            Thread.Sleep(100);
            mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
            mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0);
我的SetCursor有问题! 我不知道如何设置参数X和Y(我以前知道X,Y)。 传真:75522 有人能帮我吗?
尊敬

你只需要知道这些,我想:

如果链接已关闭:

    private void MoveCursor()
{
   // Set the Current cursor, move the cursor's Position, 
   // and set its clipping rectangle to the form.  

   this.Cursor = new Cursor(Cursor.Current.Handle);
   Cursor.Position = new Point(Cursor.Position.X - 50, Cursor.Position.Y - 50);
   Cursor.Clip = new Rectangle(this.Location, this.Size);
}

小贴士:当你需要帮助时,试着按下“F1”键。

看看@Jamaxack:wow,我发现它很久了……谢谢你,伙计!:D