Link to home
Start Free TrialLog in
Avatar of Beans0063
Beans0063

asked on

Automating data entry in Access97

Does anyone know if there's a way to have access automatically add to a table from a standard csv text file?  Something along the lines where the user clicks a button, finds the data file, then access does the rest of the work.
Avatar of deighton
deighton
Flag of United Kingdom of Great Britain and Northern Ireland image

Yes you can create a Basic module, in this module open your text file with Open and read  the file using Line Input #1 or input #1.

You'll have to devise code to process your file and the send it to your form using SendKeys

I think it is a better solution to link the csv file into the Db and then treat it as if it is a table. Then U can use Dlookup or search or whtever you want in code on thet recordset
perove
Avatar of Beans0063
Beans0063

ASKER

That's exactly what I want to do - Link the entire csv file to an existing table.  Everything is real standard here... the import wizard can do the job in one click.  Is there simply a way to hide this process from the user?
Have a look at the Transfer Text method in help. You can specify a filename (which you could get from a common dialog control) and a destination table.
ASKER CERTIFIED SOLUTION
Avatar of cymbolic
cymbolic

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial