Undefined function 'MID'

  • Thread starter Thread starter guy.jara
  • Start date Start date
G

guy.jara

I got caught up on this and I wanted to put it out into the ether. I
was experiencing a problem where a Jet SQL query was throwing an error
over the use of the very common MID function in the SQL statement. I
checked references and I had a reference to the VBA library, as well
as the Access 11.0 object library.

Then I checked with a colleague and they directed me to establish a
reference to the MS Visual Basic for Applications Extensibility
library. When I added that to my list of references, voila!, problem
solved.
 
The Mid() function doesn't require the VBA Extensibility library. However,
if *any* reference is broken, the code fails. Similarly if something else
needs a library, the code in your database won't compile, and everything is
broken.

It would therefore seem that you have some other code somewhere in your
database that needed the extra library. Or perhaps it was the kind of
corruption that could have been solved with a decompile.
 
Back
Top