Change location of control in runtime.

Hello, im trying to make label to follow my mouse cursor while my left mouse button is down.

How i get mouse position:
1
2
3
4
5
6
static int x,y;
private: System::Void pictureBox1_MouseMove(System::Object^  sender, System::Windows::Forms::MouseEventArgs^  e) {
			 x = e->X; y = e->Y;
			 label2->Text = String::Format("X = {0} ", x);
			 label1->Text = String::Format("Y = {0} ", y);
		 }


Problem is : when my mouse enters label3 code above stops getting mouse position
and i cant do for exaple this:
 
label3->Location = System::Drawing::Point(label3->Width, y);


All help much appreciated.
Topic archived. No new replies allowed.