在一个form上面移动picturebox,如果没有背景图片就没什么问题。如果给form加上背景图片,那就会变得非常卡。我在timer的tick事件里面移动picturebox请问这个问题怎么解决?

解决方案 »

  1.   

    public partial class Form1 : Form
        {
            int counts = 0;
            public Form1()
            {
                InitializeComponent();
            }        private void button1_Click(object sender, EventArgs e)
            {
                timer1.Enabled = true;
                timer1.Start();
                counts = pictureBox1.Left;
            }        private void timer1_Tick(object sender, EventArgs e)
            {
                label1.Text = counts.ToString();;
                counts++;
                pictureBox1.Left = counts;
            }
      

  2.   

    我的form1有背景图片呀,用了双缓冲还是不行~
      

  3.   

    图片不要弄得很大一张bmp
    用ps处理的小一点,尽量使用贴图来拼