Advertisement

05.16.2008 at 09:04AM PDT, ID: 23408782
[x]
Attachment Details

Wildcard Characters

Asked by bejhan in Microsoft Access Database, Visual Basic Programming, Access Coding/Macros

Tags:

I use the Dir function to retrieve a file list for a certain folder containing files that match a criteria.

Previously I was just using Dir(path & "*.xls", vbNormal) to retrieve excel files. This worked fine but now I want to restrict the criteria a bit. I have used regular expressions in UNIX but I can't seem to figure it out in MS Access. My new Dir syntax is: Dir(path & "#### Agency Items ####-???-##.xls", vbNormal)

I also tried Dir(path & "#### Agency Items ####\-???\-##.xls", vbNormal) incase dashes were special characters but no results still.

From what I understand # is any numeric character and ? is any alphabetic character.

So I would want a filename such as: 0001 Agency Items 2008-Mar-09.xls to match this.Start Free Trial
[+][-]05.16.2008 at 09:13AM PDT, ID: 21584061

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Microsoft Access Database, Visual Basic Programming, Access Coding/Macros
Tags: MS Access
Sign Up Now!
Solution Provided By: matthewspatrick
Participating Experts: 3
Solution Grade: A
 
 
[+][-]05.16.2008 at 09:31AM PDT, ID: 21584194

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 09:36AM PDT, ID: 21584241

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 09:37AM PDT, ID: 21584247

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 09:40AM PDT, ID: 21584270

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 09:45AM PDT, ID: 21584309

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 10:01AM PDT, ID: 21584423

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 10:04AM PDT, ID: 21584443

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 10:12AM PDT, ID: 21584512

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.16.2008 at 12:49PM PDT, ID: 21585852

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628