Error 459

B

Brian Smither

Received an Access 2000 database (front-end with forms and VBA code, and
backend with the main table). Since the new relative location between the
front and back ends differ, I do get the "Browse for Database" dialog.

However, and this is the quandry, it loads fine on my system at the office
(XP-Corp/SP2, Access 2003/SP2, Jet.v??) but not on my system at home (XP-
Corp, Access2003/SP2, Jet.v3.5). Nor does it load on my other system
(Server2003/SP1, Access2003, Jet.v??).

I get Run-Time error 459.

What might I have installed on my system at the office that does not cause
this error, but not having this installed on my system at home will cause
this error?

The statements that might be pertinent are:

Dim frm As Form
'Open the StatusBar form and initialize it
DoCmd.OpenForm "frmStatusBar"
Set frm = Forms("frmStatusBar") <=Error 459

I've looked around the Internet and the few hits I found do not discuss why
on one system it works - the few hits all say that the fact that it doesn't
work is by design.
 
P

Perry

Replace
Dim frm As Form
by
Dim frm As Form_frmStatusBar

What happens then?

If not helpfull, perhaps loading the form takes a bit longer than VBA
expects
causing the error y're reporting.
In this case you could test whether the target form is opened alright.
http://www.mvps.org/access/forms/frm0002.htm
You cud use it as in:

Dim frm As Form_frmStatusBar
'Open the StatusBar form and initialize it
DoCmd.OpenForm "frmStatusBar"
While not fIsLoaded("frmStatusbar")
DoEvents
Wend
Set frm = Forms("frmStatusBar")

If doesn't help either, something is bugging you.
Kindly repost

Krgrds,
Perry
 
B

Brian Smither

Replace
by
Dim frm As Form_frmStatusBar

What happens then?

"Access has encountered a problem and needs to close.
[X] Repair Database?
Send Problem Report to Microsoft? (Send)(Don't Send)]"

If not helpfull, perhaps loading the form takes a bit longer than VBA
expects causing the error y're reporting.
While not fIsLoaded("frmStatusbar")
DoEvents
Wend

That just puts Access into an infinite loop burning up 99% CPU usage.



If doesn't help either, something is bugging you.

Only on two out of three systems.
 
P

Perry

"Access has encountered a problem and needs to close.
[X] Repair Database?
Send Problem Report to Microsoft? (Send)(Don't Send)]"

Hmm, time to build up a database from scratch, import all database object
from the original one but note: EXCLUDE Form "frmStatusBar"
Compile yr VBE project, then Compile and Repair your database object and see
whether MS Access still reports an error.

I think yr form (frmStatusBar) is/got corrupt.

Krgrds,
Perry

Brian Smither said:
Replace
by
Dim frm As Form_frmStatusBar

What happens then?

"Access has encountered a problem and needs to close.
[X] Repair Database?
Send Problem Report to Microsoft? (Send)(Don't Send)]"

If not helpfull, perhaps loading the form takes a bit longer than VBA
expects causing the error y're reporting.
While not fIsLoaded("frmStatusbar")
DoEvents
Wend

That just puts Access into an infinite loop burning up 99% CPU usage.



If doesn't help either, something is bugging you.

Only on two out of three systems.
 

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

Top