Solved

Access 97 - Automating TransferText not working

Posted on 2001-06-13
3
396 Views
Last Modified: 2008-03-06
Okay, this is rather annoying.  I am trying to import data from a text file, fixed field format into my Access 97 database.  There are three files - File1.txt, File2.txt, and File3.txt (File3.txt is not always there).  I have written a macro that does a TransferText using an import specification (Shiva Import Specification) for File2.txt & File3.txt, which are in the same format.  File1.txt is also brought in using a TransferText with an import specification, and it works fine (it is formatted differently).

If I do this by hand using the same specification into the same table(File,Get External data,  Import, Select the text file, Advanced, Specs, Shiva Import Specification, and keep clicking Okay) it works fine.

Put the same information into a TransferText line on a macro, and I get this error:

Numeric Field Overflow, Which it associates with a BTrieve table.

Not sure why I'd get the error doing with a macro what I do by hand.  I do some screening on it to ensure the file exists (and that is working), but the error is driving me nuts.  Any suggestions?  Thanks.
0
Comment
Question by:kaldrich
  • 2
3 Comments
 
LVL 57

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 250 total points
ID: 6186800
It's hard not to think of Access as one big program, but it's really made up of three: Access UI, VBA, and JET.

You get a difference because you really are doing it two different ways.  One is through the Access UI, the other through VBA.

I'd try setting up a schema.ini file for the import file. Here's a MSKB link:

http://support.microsoft.com/support/kb/articles/Q149/0/90.asp

HTH,
Jim.

0
 

Expert Comment

by:amp072397
ID: 6742511
kaldrich hasn't logged in since early November. Points will be awarded to JDettman in about 7 days unless kaldrich returns with a viable objection.

thanks!
amp
community support moderator
0
 

Expert Comment

by:amp072397
ID: 6758939
Points to JDettman.
amp
community support moderator
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Best way to create dynamic, short cut menu 7 27
vba sql wild card passing in code 3 21
User Level Security 6 36
Microsoft Access - Stopping Control - (minus) 4 28
I originally created this report in Crystal Reports 2008 where there is an option to underlay sections. I initially came across the problem in Access Reports where I was unable to run my border lines down through the entire page as I was using the P…
I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

813 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now