February 2008 - Posts
one of the easiest way to get the mouse coordinates on the form is by using an ready attribute ,this attrbute is on the Control Class ,MousePosition and here you will get and x and y Coordinates for the mouse just in the moment of the running the application , so to get this coordinates dynamically you can bind this with MouseMove event for the form which you want to get mouse movment like this :
private void Form1_MouseMove(object sender, MouseEventArgs e)
{
label5.Text = "X : " + Control.MousePosition.X.ToString();
label6.Text =
"Y : " + Control.MousePosition.Y.ToString();this.Refresh();
}
I hope thats help
i will try with you to share and develop a a helpfull blog that i hope to be one of the most WindowsClients success blog.
since, it my first blog on the internet , i hope to help me by asking quesitons and suggesting topices to discuess.
Bassl Kokash