Dim Filter As String
Filter = "[行政村] = '**村' "
Tables("分村统计表").Filter = Filter
MainTable = Tables("分村统计表")
以下代码需修改:
Dim i As Integer
For i = 1 To MainTable.RecordCount
MainTable.EditCurrentRecord
MainTable.Fields("序号").Value = i
MainTable.UpdateCurrentRecord
Next i
for i as integer = 0 to
Tables("分村统计表").rows.count - 1Tables("分村统计表").rows(i)("序号") = i+1
next