Stored Import Specs?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I've created a standard specification for importing this CSV file. The
problem is, I don't want my end users to have to click Import, etc. to get
this file into a table. Is it possible to automatically call this
specification from within Access, say a button on a form? If so, where is
the specification stored?
 
I've created a standard specification for importing this CSV file. The
problem is, I don't want my end users to have to click Import, etc. to get
this file into a table. Is it possible to automatically call this
specification from within Access, say a button on a form? If so, where is
the specification stored?

If you have already created the import specification (and have named
it), your user doesn't need to 'get into it' to import the file in the
future.
Look up the TransferText method in VBA help.
The 2nd argument is the import spec name.

In the Click event of a command button:

DoCmd.TransferText acImportDelim, "SpecName", "TableName", "c:\my
folder\FileName.txt"
 
Thank you Fred - that's exactly what I needed!


fredg said:
If you have already created the import specification (and have named
it), your user doesn't need to 'get into it' to import the file in the
future.
Look up the TransferText method in VBA help.
The 2nd argument is the import spec name.

In the Click event of a command button:

DoCmd.TransferText acImportDelim, "SpecName", "TableName", "c:\my
folder\FileName.txt"
 
Back
Top