Me.Height 改变了吗?而且最好不要用Me.Height,应该用Me.ScaleHeight:Picture1.Height = Me.ScaleHeight

解决方案 »

  1.   

    要让picturebox控件跟着窗体变化而动,要用
    picture1.move me.scaleleft,me.scaletop,me.scalewidth,me.scaleheight-100
    用move方法可以移动控件的!try it!
      

  2.   

    还是不行呀
    回复zyl910:会说ScaleHeight是无效参数回复popo7018(哲) : 我只要改变它的height呢
      

  3.   

    当Form大小变化时,在ReSize事件中设Picture1.Height = Me.Height - 100
    只会改变PictureBox的长度,不是位置.
    你的代码只是让picture的大小随Form变化而变化,我看不出你想让commandbutton移动的代码在哪?
    要移动按钮的话,在Form_ReSize中
    Picture1.Height=Me.Height-100
    CommandButton1.Top=Picture1.Height-dis
    'dis是你想让Button距Picture1的底部的距离,你可以自己设定,比如100