public Form1()
{
InitializeComponent();
this.imgRoom.Click += new EventHandler(this.pictureBox1_Click);
}
private void pictureBox1_Click(object sender, EventArgs e)
{
var label1 = new LabelControl();
label1.Location = MousePosition;
label1.BackColor = Color.Red;
label1.Parent = imgRoom;
label1.Text = "Point";
imgRoom.Controls.Add(label1);
}
當我在的地方,你可以連接的屏幕上看到的點擊,點出現在另一個地方。如何解決這個問題呢?
太好了。萬分感謝 :) –