Avatar of Andy Donnelly
Andy Donnelly
Flag for United States of America asked on

Importing Excel into Access 2016

I'm using a macro in Access 2016 to import an excel file.  The user inputs the filename into a text box on a form and I need to pass that name to the field name the ImportExportSpreadsheet step in the macro.  It seems no matter how I format the name of the form/field it doesn't work.  I've tried [forms]![formname]![filename] but the macro says it can't find the file and generates a 2950 error.
Microsoft AccessMicrosoft ExcelMicrosoft Office

Avatar of undefined
Last Comment
Andy Donnelly

8/22/2022 - Mon
als315

Can you upload sample with this macro?
ASKER CERTIFIED SOLUTION
als315

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
SOLUTION
Scott McDaniel (EE MVE )

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Andy Donnelly

ASKER
I was missing the = sign in the expression.  Looking at your screen shot solved my issue.

Thanks!
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23