以下是引用贺老六在2008-9-19 16:43:00的发言: 标准答案:
Dim Filter As String
For Each dc As DataCol In DataTables("表A").DataCols
If Filter > "" Then
Filter = Filter & " And "
End If
Filter = Filter & dc.Name & " Is Null"
Next
DataTables("表A").DeleteFor(Filter)
[此贴子已经被作者于2008-9-19 16:45:28编辑过]
呵呵,站在巨人肩上,精简些:
Dim Filter As String
For Each dc As DataCol In DataTables("表A").DataCols
Filter = Filter & " and " & dc.Name & " Is Null"
Next
DataTables("表A").DeleteFor(Filter.SubString(5))