Set fd = Application.FileDialog(3)
fd.Title = "Select Files"
fd.AllowMultiSelect = True
fd.Filters.Clear
fd.Filters.Add "CSV File",
If fd.Show = True Then
For Each varFile In fd.SelectedItems
sFile = varFile
db.TableDefs.Refresh
DoCmd.TransferText , TableName:="temp", _
FileName:=sFile, HasFieldNames:=True
.
.
Next
End If
即使用户选择多个文件,它也只是读取第一个文件。这是为什么 ?请帮忙