Hello-
I have a tab delimited text file users will download and by pushing the import list button will get a Browse function which allows them to find the location of that text file. However, I'm not sure how to take the text file and then import it into my database. I have column headers on the text file. I created the Import/export wizard Object but not sure how to access that object once I've chosen my text file location in VB? Any help is appreciated.
Private Sub ImportList_Click()
On Error GoTo Finish
' Select Folder
' See the 'BrowseFolder' function in module 'BrowseForFolder'
Dim strFolderName As String
Dim strCaption As String
' Open the text file
strCaption = "Select folder to load Listings from"
strFolderName = BrowseFolder(strCaption)
If Not IsEmpty(strFolderName) Then
strSearchSpec = strFolderName + "\" + "*.txt"
strFile = Dir(strSearchSpec, vbNormal)
End If
Finish:
End Sub
I have a tab delimited text file users will download and by pushing the import list button will get a Browse function which allows them to find the location of that text file. However, I'm not sure how to take the text file and then import it into my database. I have column headers on the text file. I created the Import/export wizard Object but not sure how to access that object once I've chosen my text file location in VB? Any help is appreciated.
Private Sub ImportList_Click()
On Error GoTo Finish
' Select Folder
' See the 'BrowseFolder' function in module 'BrowseForFolder'
Dim strFolderName As String
Dim strCaption As String
' Open the text file
strCaption = "Select folder to load Listings from"
strFolderName = BrowseFolder(strCaption)
If Not IsEmpty(strFolderName) Then
strSearchSpec = strFolderName + "\" + "*.txt"
strFile = Dir(strSearchSpec, vbNormal)
End If
Finish:
End Sub