是否要改成这样呢?
BeforeAddDataRow事件:
If CurrentTable.Rows.Count <= 0 Then
Return
End If
Dim r As Row = CurrentTable.Current
If r.isNull("第一列") Orelse r.IsNull("第三列") OrElse r.IsNull("第五列") Then
e.Cancel = True
End If
BeforeSelChange事件:
If CurrentTable.Rows.Count <= 1 Then
Return
End If
Dim r As Row = CurrentTable.Current
If r.isNull("第一列") Orelse r.IsNull("第三列") OrElse r.IsNull("第五列") Then
If e.NewRange.RowSel <> e.OldRange.RowSel Then
e.Cancel = True
End If
End If