Runtime Error '5'

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

Guest

Dear all

I have a problem on my Access database.

It is developed on Access 2003 SP2, with 2000 format.
I designed the Forms for resolution 1024x768.

Some how, runtime error '5' occurred when my users open the Forms, with
Access 2003 SP1 or with resolution different from 1024x768.

But, for users using Access 2000 or Access 2003 SP2 with resolution
1024x768, there is no problem.

Moreover, because the computers of some users are having 16:9 screen and
using 1280x768 resolution, so it is not convenience to ask them change the
setting everytime when they use the database.

Can you help to provide some solutions?

Thanks & regards
Eddy
 
Runtime Error 5 is "Invalid procedure call or argument", so it's hard to see
how resolution could be causing the problem.

Have you tracked down what line of code is raising the error?
 
Hi

When debug, the following code being highlighted:

If IsNull(Me.Vacancies_Form.Form.RecordSource) Or
Me.Vacancies_Form.Form.RecordSource = "Vacancies Query" Then

Where "Vacancies_Form" is a sub-form.

Thanks to investigate.

Eddy
 
Where is that code: in the module associated with the form that contains the
subform, or in the module associated with the form that's being used as a
subform? (It needs to be in the form that contains the subform)

In what event is the code?

While Vacancies_Form may be the name of the form that's being used as a
subform, is it the name of the subform container on the parent form?
Depending on how the subform was added, the container may be named something
else.

Finally, there's no reason for the IsNull check. RecordSource will never be
Null: it's a zero-length string if it's an unbound form.
 

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