How to get cursor position in C#
In future if you are working on any Game Development project or any project where you need to find the current cursor position, this simple program might help you.
Code(.cs file) :
namespace CursorPosition
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
this.MouseMove+=Form1_MouseMove;
}
void Form1_MouseMove(object sender, MouseEventArgs e)
{
cursorPositionLabel.Text = e.Location.ToString();
}
private void Form1_Load(object sender, EventArgs e)
{
}
}
}