老师,代码是这样:
Dim t As Table = Tables("pos刷卡明细导入2")
t.StopRedraw()
For Each fl As String In dlg.FileNames
Dim Book As New XLS.Book(fl)
Dim Sheet As XLS.Sheet = Book.Sheets(0)
For n As Integer = 4 To Sheet.Rows.Count-2
Dim r As Row = t.AddNew()
For i As Integer = 0 To sheet.Cols.Count - 2
Dim cname As String = sheet(3, i).text
If t.Cols.Contains(cname) Then
Dim s As String = sheet(n, i).Text
r(cname) = s
output.show(s)
End If
Next
Next
Next
t.ResumeRedraw()
进入的日期时间列只有日期,我已经把列属性改为日期时间了,不知道什么原因。。。
此主题相关图片如下:微信截图_20181023152532.png
此主题相关图片如下:微信截图_20181023152401.png
[此贴子已经被作者于2018/10/23 15:27:42编辑过]