AllExperts > Experts 
Search      

Visual Basic

Volunteer
Answers to thousands of questions
 Home · More Questions · Answer Library  · Encyclopedia ·
More Visual Basic Answers
Question Library

Ask a question about Visual Basic
Volunteer
Experts of the Month
Expert Login

Awards

About Us
Tell friends
Link to Us
Disclaimer

 
 
 
 
About Richard Rost
Expertise
I can answer any questions pertaining to Microsoft Visual Basic 6.0, Microsoft Access VBA, and the Visual Basic Language in general. I do NOT use VB.NET or VB 2005/08 much yet, so don't ask me any questions specific to those. Also, please feel free to check the Tips & Tricks section of my web site for VB tips.

Experience
I am the president of VBLearningZone.com and 599CD.com. I specialize in Microsoft Access and Visual Basic Tutorials. I have been teaching in the classroom since 1994, and online since 2002.

Education/Credentials
I am a self-taught VB expert. I have been building software for clients since the early 90s (and on my own since I was a child). You can see a sample of my Tutorials on my web site at 599CD.com

 
   

You are here:  Experts > Computing/Technology > Basic > Visual Basic > DIR function missing in Access 2003

Topic: Visual Basic



Expert: Richard Rost
Date: 8/15/2008
Subject: DIR function missing in Access 2003

Question
The following code used to work but now it is giving this error "The expression you entered has a function name that Microsoft Office Access can't find"

"CUNAREQ.XLS"=UCase(Dir("smpftpp02AshBrkrgeSCUNAREQ.xls"))

Have tried going into references and unchecking a resource and then going back in and rechecking it but the error persists. Don't see DIR listed in the list of Built-In Functions.  Typing ?Dir("C:autoexec.bat") in the Immediate window returns autoexec.bat.  Is this a missing reference or another problem?  If it's a reference, what needs to be selected or added?

Answer
This should work fine for you:

X=UCase(Dir("smpftpp02AshBrkrgeSCUNAREQ.xls"))

But you can't assign it to another string like you have in your question. DIR is still a valid function, as is UCASE.

Let me know if you have any other questions or comments.

Also, be sure to visit my web site and watch my FREE 90-minute MICROSOFT ACCESS VIDEO TUTORIAL. Go to http://www.599cd.com/Access/AllExperts


Cordially,

Richard Rost
599CD Computer Training
http://www.599cd.com

P.S. Also, don't forget to visit my FREE Microsoft Access Tips & Tricks Page at http://www.599cd.com/Tips/AllExperts

P.P.S. I volunteer my time at AllExperts to help people, and I get a LOT of questions, so I can't take an hour to answer each question. If you need more DETAILED HELP, come to my TechHelp web site at http://www.599cd.com/TechHelp/AllExperts and I'll take as much time as you need to answer your question.

http://www.599cd.com/Microsoft_Access_Tutorial

Add to this Answer    Ask a Question



  Rate this Answer
   Was this answer helpful?
Not at allDefinitely              
   12345  

     
About Us | Advertise on This Site | User Agreement | Privacy Policy | Help
Copyright  © 2008 About, Inc. About and About.com are registered trademarks of About, Inc. The About logo is a trademark of About, Inc. All rights reserved.