文件名称:vb
介绍说明--下载内容均来自于网络,请自行研究使用
假设 Form1 窗体有 MSFlexGrid1 控件,在 Form1 代码窗口贴下面代码,MSFlexGrid1 和其中单元格就会跟着窗体大小变化而变化:- gridTopRatio = .Top/Me.Height
gridWidthRatio = .Width/Me.Width
gridHeightRatio = .Height/Me.Height
ReDim colWidthRatio(.Cols- 1)
ReDim rowHeightRatio(.Rows- 1)
For i = 0 To .Cols- 1
colWidthRatio(i) = .ColWidth(i)/Me.Width
Next i
For i = 0 To .Rows- 1
rowHeightRatio(i) = .RowHeight(i)/Me.Height
Next i
End With
End Sub
gridWidthRatio = .Width/Me.Width
gridHeightRatio = .Height/Me.Height
ReDim colWidthRatio(.Cols- 1)
ReDim rowHeightRatio(.Rows- 1)
For i = 0 To .Cols- 1
colWidthRatio(i) = .ColWidth(i)/Me.Width
Next i
For i = 0 To .Rows- 1
rowHeightRatio(i) = .RowHeight(i)/Me.Height
Next i
End With
End Sub
(系统自动生成,下载前可以参看下载内容)
下载文件列表
vb.doc