Q: How to find reference filename

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

We're using Access 2003 in our office. I created a form using the filedialog
method, which requires Microsoft Office 11.0 object library, which I have,
but some others don't.

So
1) What is the name of that file I have to add and how do I add it?
2) Tools | References tells me the name of the file, but the path is
truncated and I can't see the full name of the file. How do I go about seeing
the full name of the file in general when it's truncated?

Thanks!
-Mark
 
Hi Mark,

You need a reference set to the Microsoft Office 11.0 Object Library. I
don't know if you can legally distribute the required file, if the target
PC's lack this reference. To determine the full paths of all checked
references, you can use code like this to print the paths to the Immediate
window:

Function EnumerateReferences()
Dim refItem As Access.Reference
Dim iRefCount As Integer

For Each refItem In Application.References
iRefCount = iRefCount + 1
Debug.Print "Reference #" & iRefCount & ": " & refItem.FullPath
Next refItem

End Function


My advise is to forget about the filedialog method, and use API code
instead. This way, you should not have to worry about a given PC lacking the
required reference. Here is a link to a page that shows you how to do this:

API: Call the standard Windows File Open/Save dialog box
http://www.mvps.org/access/api/api0001.htm


Tom Wickerath
Microsoft Access MVP

http://www.access.qbuilt.com/html/expert_contributors.html
http://www.access.qbuilt.com/html/search.html
__________________________________________
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top