Results 1 to 2 of 2
  1. #1
    MTSPEER is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jun 2013
    Posts
    283

    Importing Text File into Table

    Hello,

    I'm having some problems importing a text file into a specific table in Access. The table already has field names. And there will be multiple text files within the folder I'm using. All the files in the folder will be named similarly. For example TEST_EEAF1, TEST_EEAF2, etc. I want it to pull the most recent file that it was updated. The table name is TEST_EEAF. Here is the code I have now:

    Public Sub ImportEEAF()


    Dim File1 As String

    File1 = Dir("\\abc.com\dept\PAMO1\SPI\Projects\STT\Persona l\Mark Spuur\Test1\TEST_EEAF_CCP.txt")

    Dir ("\\abc.com\dept\PAMO1\SPI\Projects\STT\Personal\M ark Spuur\Test1\TEST_EEAF_CCP.txt")

    DoCmd.TransferText acImportDelim, "", "TEST_EEAF", ("\\abc.com\dept\PAMO1\SPI\Projects\STT\Personal\M ark Spuur\Test1" & File1)


    End Sub
    Last edited by June7; 01-16-2015 at 01:12 PM.

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,931
    What are the 'problems'? This appears to be duplicate topic. A solution was offered in https://www.accessforums.net/program...ate-49623.html

    How does it not meet need?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 11-05-2013, 04:14 PM
  2. Replies: 2
    Last Post: 01-30-2013, 06:48 AM
  3. Importing a text file
    By Kurs in forum Access
    Replies: 11
    Last Post: 02-20-2012, 02:26 PM
  4. Replies: 1
    Last Post: 11-05-2010, 04:31 PM
  5. Importing text file into Access Table
    By Anthony in forum Import/Export Data
    Replies: 13
    Last Post: 09-23-2009, 04:47 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums