Solved

Accessing Text File from a VBA module of MS Access

Posted on 1997-05-26
1
207 Views
Last Modified: 2010-04-12
I need to load some data into Access database which is in a text format, and I wanted to write a VBA module which will parse the text file and store the data into the database.  But I can't figure out how to access a text file from a VBA module.  Any help would very much be appreciated
0
Comment
Question by:karim
1 Comment
 
LVL 1

Accepted Solution

by:
jimlam earned 50 total points
ID: 1009166
Hi Karim,

You need to use the OPEN statement to open a file like:

OPEN "ABC.TXT"" For Input As #1

Then use INPUT, LINE INPUT or other functions to get the text in, use the EOF function to check for end-of-file. And lastly, use CLOSE to close the text file.

Good luck,
Jim
0

Featured Post

Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
strings to secure devices 8 94
Fastest SSD 10 83
Dell T5810 (and which processor) or Dell XPS 8910 Special Edition 6 89
Graphics card for a new Dell 5810 workstation 16 108
Great sound, comfort and fit, excellent build quality, versatility, compatibility. These are just some of the many reasons for choosing a headset from Sennheiser.
This paper addresses the security of Sennheiser DECT Contact Center and Office (CC&O) headsets. It describes the DECT security chain comprised of “Pairing”, “Per Call Authentication” and “Encryption”, which are all part of the standard DECT protocol.
In a recent question (https://www.experts-exchange.com/questions/28997919/Pagination-in-Adobe-Acrobat.html) here at Experts Exchange, a member asked how to add page numbers to a PDF file using Adobe Acrobat XI Pro. This short video Micro Tutorial sh…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question