Dim App As New MSExcel.Application
Dim Wb As MSExcel.WorkBook = App.WorkBooks.Open(a.Value)
Dim Ws As MSExcel.WorkSheet = Wb.WorkSheets(b.Value)
For n1 As Integer = 1 To 2500
Dim r As Row = Tables("订单表").AddNew()
For m As Integer = 1 To 10
If IsNumeric(ws.cells(n1,m).value) Then
r(m+4) =val( ws.cells(n1,m).value)
End If
r(m + 4) = trim(ws.cells(n1,m).value)
r(m + 4) = r(m).replace(" ","")
Next
Next
大师:以上这段代码读取2500多行数据要两分钟,请问如何改进提高效率?