fpspread控件如何实现删除选中的多行,网上找到的代码,好像哪里不对。各位给帮忙看一下。
Private Sub Command3_Click()Dim i As Integer
Dim r, c, r2, c2 As Integer
For i = fpSpread1.SelectionCount - 1 To 0 Step -1
fpSpread1.GetSelection i, c, r, c2, r2
fpSpread1.DeleteRows r, r2 - r + 1
fpSpread1.MaxRows = r2 - r + 1
Next i
End Sub