vb MSHFlexGrid 中新增一行时自动选中新增的那一行并变色
2个回答
展开全部
Private Sub Form_Load()
MSHFlexGrid1.SelectionMode = flexSelectionByRow
MSHFlexGrid1.Rows = 5
MSHFlexGrid1.Cols = 4
End Sub
‘双击需要添加的行,在双击行的上面添加一行并选中
Private Sub MSHFlexGrid1_DblClick()
Dim i As Integer
With MSHFlexGrid1
i = .Row
.AddItem i, i
End With
End Sub
MSHFlexGrid1.SelectionMode = flexSelectionByRow
MSHFlexGrid1.Rows = 5
MSHFlexGrid1.Cols = 4
End Sub
‘双击需要添加的行,在双击行的上面添加一行并选中
Private Sub MSHFlexGrid1_DblClick()
Dim i As Integer
With MSHFlexGrid1
i = .Row
.AddItem i, i
End With
End Sub
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询