mshflexgrid如何随窗体的大小自动调整大小

解决方案 »

  1.   

    mshflexgrid.move .....
    自已查一下
      

  2.   

    form_onresize事件中根据窗体的top,left,width,weight来定位就可以了
      

  3.   

    Private Sub Form_Resize()
        Dim sHeight As Integer
        Dim sWidth As Integer
            
        sWidth = Me.Width - 400
        If sWidth > 0 Then
            mshflexgrid.Width = sWidth
        End If
            
        sHeight = Me.Height - Me.myFrame.Height - 1000
        If sHeight > 0 Then
            mshflexgrid.Height = sHeight
        End If
    End Sub在窗体的这个事件里 放改变表格大小的代码!