Errors opening Excel file from within Access

wilkisa

Well-known Member
Joined
Apr 7, 2002
Messages
657
Office Version
  1. 365
  2. 2016
  3. 2013
Platform
  1. Windows
My user has created a small switchboard in Access. He has a dropdown box that contains, for example, 1ST GRADE, 2ND GRADE, 3RD GRADE. He then has a command button that is designed to search his file folders for any filenames that contain the string that is selected in the dropdown box. The problem is the space in the string causes an error.

Example: suppose he selects 1ST GRADE. It should search for all files with 1ST GRADE in the name. He gets an error that says the file 1ST.XLS can't be found; then he gets an error that says the file GRADE.XLS can't be found. Any way to make the two words stay together?

Thanks for any help we can get!!!
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
Thanks, Anvil19, that is the answer I was looking for. I had searched for this topic but didn't find this response.

I appreciate the help.
 
Upvote 0

Forum statistics

Threads
1,221,700
Messages
6,161,371
Members
451,700
Latest member
Eccymarge

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top