Invalid argument

  • Thread starter Thread starter Paul Camilleri
  • Start date Start date
P

Paul Camilleri

I have a small Access database for our church records.
It is split into a "front end" and a "back end" and is
configured to run in Access 2000. I developed it myself
and as I am not a programmer I have had to make do with
macros, where I was not able to use a wizard to produce
code. It has been working well until now, but today, I
have been getting "Invalid argument" when running some
queries. I have been through them all and there is
nothing wrong with them. When I run the forms that
depend on those queries, all the fields populate with
#NAME?

I have tried to run my backup versions of the database,
which were working well and they are all doing the same
thing. I have recently installed the Office XP Update:
KB833858 (English version) and I wonder if that might
have something to do with the problem I am experiencing.

I would be most grateful for any assistance.

Paul Camilleri
 
To do its job, Access (like most modern programs) makes use of various
external program and object libraries that provide functionality that may be
shared among applications. For example, Access always uses the Visual Basic
for Applications library, the version-appropriate Access Object Library, and
the OLE Automation library. References to the specific library files,
including their locations, are stored with your database. But these library
modules may not be in the same location on different machines, especially if
they have different versions of Microsoft Office. If you move a database
from one machine to another, these references may be "broken"; that is, one
or more of the library files may not be where the stored reference says it
is.

When this happens, you need to take steps to let Access repair the broken
reference(s) ON THE COMPUTER WHERE THE FAILURE IS OCCURING.

Here are Doug Steele's instructions for how to do it:

****Quote****
Open any code module (or open the Immediate Window, using Ctrl-G, provided
you haven't selected the "keep debug window on top" option). Select Tools |
References from the menu bar. Examine all of the selected references.

If any of the selected references have "MISSING:" in front of them, unselect
them, and back out of the dialog. If you really need the reference(s) you
just unselected (you can tell by doing a Compile All Modules), go back in
and reselect them.

If none have "MISSING:", select an additional reference at random, back out
of the dialog, then go back in and unselect the reference you just added. If
that doesn't solve the problem, try to unselect as many of the selected
references as you can (Access may not let you unselect them all), back out
of the dialog, then go back in and reselect the references you just
unselected. (NOTE: write down what the references are before you delete
them, because they'll be in a different order when you go back in).

Just so you know: the problem will occur even if the library that contains
the specific function that's failing doesn't have a problem.
****Unquote****

So, follow those instructions and see if your problem goes away.

Check out the following reference
http://www.trigeminal.com/usenet/usenet026.asp?1036
 
Thank you very much for your advice. No library references were missing,
but I selected an additional reference then backed out, went back in and
deselected it and the problem was solved.

I am most grateful.

Paul
 
I am afraid I was a bit premature. The problem has come back again and
deleting and adding back references in the front and back end databases now
has no effect.

I have tried creating a new blank database and importing all objects. I
started with the back end and selected all tables, but one table gave an
"Invalid argument" message and was not imported. I have examined all the
fields in the table, but can see nothing wrong. I have not yet tackled the
front end.

Do you have any further suggestions?

Paul
 
I have found the problem. One row of data in the faulty table was corrupt
and showing #ERROR all the way across the datasheet. I had to remove all
the relationships to that table and remove the Primary Key before I could
delete the row. Everything is fine now.

Thank you once again.

Paul
 
Good work. Glad you found it. I was going to suggest that you try the steps
you did and look for corruption in the table. Just got up and got ready for the day.
 
Back
Top