Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

docmd.TransferText not importing a number field

Status
Not open for further replies.

JayRo71

Technical User
May 13, 2020
53
US
I have the following line of code...


DoCmd.TransferText acImportDelim, "Chart Import Specification", "tblMeterReads", fileName, True, , 1252

I can manually run chart import specification with no problem. When I use DoCmd TransferText it imports all of the records, but skips a field that has decimals in it. I have recreated the import specification several times and it works manually without any problem which rules out a data type mismatch, a key violation, or a typo in the field name.

Thank you for any suggestions.
 
It is unusual that I solve my own questions, but I did. It turns out that even though the number was showing as a short decimal when opened in excel, it was actually a Large Number. So my data type was wrong. It only took me 4 hours to figure it out. I am leaving this post incase anyone else ever has a similar issue.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top