Imorting a txt file with no line breaks

  • Thread starter chris thorn via AccessMonster.com
  • Start date
C

chris thorn via AccessMonster.com

Hi all

I am importing a text file that has fields delimited with a "|" and the end of the record is denoted with a "@"
Ther are no line breaks i.e. The data is presented as "|smith |ron |12345|@|jones | barry |67892|@" a new record is not started on each line. How can I automate the import of such a file? I cannot see any feature in the import wizard that shows an end of record.

Thanks

Chris

*****************************************
* This message was posted via http://www.accessmonster.com
*
* Report spam or abuse by clicking the following URL:
* http://www.accessmonster.com/Uwe/Abuse.aspx?aid=a8e1e2bd1d8e4bfc8c982e02281a244f
*****************************************
 
D

Douglas J. Steele

You won't be able to use the import wizard for that.

You'll either have to change the text file before you try to import it, or
write VBA code to use basic file I/O (Open, Get, etc.) to read the text in
so that you can parse it and write it to the database yourself.

--
Doug Steele, Microsoft Access MVP

(no e-mails, please!)



chris thorn via AccessMonster.com said:
Hi all

I am importing a text file that has fields delimited with a "|" and the
end of the record is denoted with a "@"
Ther are no line breaks i.e. The data is presented as "|smith |ron
|12345|@|jones | barry |67892|@" a new record is not started on each
line. How can I automate the import of such a file? I cannot see any feature
in the import wizard that shows an end of record.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top