library reference

H

Holbrook

I have made a runtime version of a database with Access 2003. In the runtime
version the Date function in a form shows up as #Name. On the web people
suggest a problem with a reference library. How do I fix this problem or how
fo I find what library is missing from the PC with the runtime version? I
have installed the latest service pack on the runtime PC.
 
A

Allen Browne

Use your development version to list the names of the libraries your
database requires:
Function ShowRef()
Dim ref As Reference
For Each ref In Application.References
Debug.Print ref.Name, ref.FullPath
Next
End Function

On the runtime installation where it fails, each of those libraries must be
correctly registered. It does not have to be in the same path, but it does
have to be the same version of the file, so you will need to go to each of
those files on your system, right-click and jot down the version.

To avoid that kind of problem and keep support to a minimum, remove any
references you do not need. A typical Access application needs only 3
libraries: VBA, Access, and DAO. If you need others, make sure that you
install them as part of your runtime release package.

More info on references:
http://members.iinet.net.au/~allenbrowne/ser-38.html
 
H

Holbrook

Checked all the libs. Basically, the runtime puts stuff in C:\program
Files\Microsoft Office and on the development machine its in Microsoft Office
2003. I tried to correct this by moving files and changing registry entries
but it had no affect.
Now function works perfectly and date just does not work.
Considering this is a very basic function and I am using a packaging wizard
I think its a pretty poor development tool.
I also tried putting the date function into an event liek After update of a
filed on a form and that works as well. Just using default value on a form
does not work in the runtime.

Thanks for your help.
Any other suggestions are welcome.
Richrd
 
A

Allen Browne

Don't know if it will make any difference, but I always use the equal sign
in the default value property when referring to a function:
=Date()

The other thing to check for might be any object named Date, e.g. a field or
table or form that might confuse Access.
 
Top