View Full Version : Undefined function 'Mid'


fintanm
10-03-2007, 05:20 PM
Hi, I am recieving an undefined function in 'Mid' expression error when running a query, I have used this in similar circumstances in other DB's but it just won't work here.

store: Mid([tbl_store_data].[profitctr],2,4)

Any suggestions?

RuralGuy
10-03-2007, 05:31 PM
Have you checked to see if you have any reference (http://www.accessmvp.com/djsteele/AccessReferenceErrors.html) problems?

fintanm
10-03-2007, 05:35 PM
I have checked that all my references are the same for another database where the Mid function does work, however I am unsure of the specific reference that Mid would be refering to

boblarson
10-03-2007, 05:39 PM
I have checked that all my references are the same for another database where the Mid function does work, however I am unsure of the specific reference that Mid would be refering to

It deals with the MSCOMCTL.OCX file and so you should be able to fix it by just going to Tools > References and in the dialog click the browse button and browse to that file (if in XP it would be under C:\Windows\System32 folder). Use Windows search if you can't find it.

RuralGuy
10-03-2007, 05:43 PM
It is also possible that you could have a *bogus* MISSING reference that simply needs to be deleted. Check the link I posted.

fintanm
10-03-2007, 05:49 PM
Thanks for the assistance, I added the referrence boblarson mentioned, didn't help, I will go through the link you provided RG. Let you know how I go. FM.

fintanm
10-03-2007, 07:10 PM
Thanks, problem rectified, missing Activex component