Hi
U can do it by comparing the rowheight to the control height. This code assumes that each row is the same height.
Regards
Stuart
VB Code:
Private Sub Command1_Click() With MSFlexGrid1 .AddItem "test" & vbTab & "test" & vbTab & "test" If .Rows * .RowHeight(0) > .Height Then .ColWidth(2) = 1000 End If End With End Sub




Reply With Quote