Run TIme Error 3349 on Front end only (1 Viewer)

Locopete99

Registered User.
Local time
Today, 01:58
Joined
Jul 11, 2016
Messages
163
Hi Guys,

I have a strange issue that I cannot work out.

I have an excel import into a table.

The table comprises of 5 columns. ID (Which is being imported blank so the table can auto number it. Also the Primary Key), Usercode, CourseID, Progress and Mail.

All are number fields and set as number fields.

If I try and import through a macro on my front end, I get a Run time 3349 error. However, when manually importing the spreadsheet into the back end, the data goes in fine with no error.

I've attached the code below for the import, but I can't figure out why the manual import is fine but the vba code on the front end is erroring.

Code:
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel12, "tbl_progress", file1, True
 

JHB

Have been here a while
Local time
Today, 09:58
Joined
Jun 17, 2012
Messages
7,732
What is Run time 3349 error?
 

gemma-the-husky

Super Moderator
Staff member
Local time
Today, 08:58
Joined
Sep 12, 2006
Messages
15,613
3349 = numeric field overflow

you probably have a field set as an integer, with a value greater than approx 32000
or a field set as a long with a value greater than approx 2Billion.

but I don't see why it would work manually, and not automatically.
is tbl_progress in the front end, or the back end, when you import using the code?
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 03:58
Joined
Feb 28, 2001
Messages
26,996
The only thing I might suggest is to manually examine the table definition in the front end and then directly open the back end to compare definitions. The FE version is, of course, a linked table. Therefore in the FE it has definitions of all the fields, but it has a pointer to the BE's actual table. But to do the linking, the BE definition had to exist first in order to be copied to the FE. If there is a difference between the two definitions other than location, it would be good to check that. It might be a subtle type of corruption, 'cause that DOES happen now and then with Access.

You could also dissolve and recreate the FE definition just for snorts & giggles.
 

Users who are viewing this thread

Top Bottom