我想把工作簿中的所有数据表合并到“收款”一个表中,代码为:Dim dlg As New OpenFileDialog '定义一个新的OpenFileDialogdlg.Filter= "Excel文件|*.xls;*.xlsx" '设置筛选器
If dlg.ShowDialog = DialogResult.Ok Then '如果用户单击了确定按钮
Dim Book As New XLS.Book(dlg.FileName)
Tables("收款").StopRedraw()
For i As Integer = 0 To Book.Sheets.Count -1
Dim Sheet As XLS.Sheet = Book.Sheets(i)
Dim nms() As String = {"债权人","借款日期","借款期限","利率","收取金额","piao号","凭证号","备注"}
For n As Integer = 1 To Sheet.Rows.Count -1
Dim r As Row = Tables("收款").AddNew()
For m As Integer = 0 To nms.Length - 1
r(nms(m)) = Sheet(n,m).Value
Next
Next
Next
Tables("收款").ResumeRedraw()
End If
DataTables("收款").Deletefor("piao号 is null")
最后只导成功一条,请问代码要如何修改?谢谢,请指教!