For loop not initialized

B

Brian Bishop

Using Access 2003, with linked tables, whenever I try to use Performance
Analyzer a small box opens with "For loop not initialized". Nothing else
happens and there is no Help button to use; my database continues to function
apparently OK.

Needless to say, Performance Analyzer does not function. Any ideas?
 
G

Graham R Seach

Brian,

Open any code module, then select Compile from the Debug menu. Fix whatever
error is reported. Repeat this procedure until no more errors are reported.
Then retry Performance Analyzer.

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia
 
B

Brian Bishop

Graham
Thank you for your interest. I have done what you suggest, but it has not
made any difference. In all other respects, the database (sized around 26mb)
appears to work OK, although sometimes 'Compact & Repair' produces a fault
report. Other times it works OK.
 
G

Graham R Seach

Brian,

I can find no helpful reference to this issue anywhere, so unfortunately
there are only two things I can think of. Try the first suggestion, and if
that doesn't resolve it, try the second.

1. Decompile the database.
a). Create a Windows shortcut.
b). Right-click the shortcut, and select Properties.
c). In the Target box, you'll see the path to the database.
d). Add the path (enclosed in double quotes) to msaccess.exe to the left
of the database's path, adding a space between them.
e). Add the /decompile switch to the right of the database's path,
adding a space between them.
"path to msaccess.exe" "path to database" /decompile
f). Click OK.
g). Double-click the shortcut to launch the database.
h). Compact & Repair the database, then close it.
i). Re-open the database in the normal way (without using the shortcut).
j). Open any code module, and select Compile from the Debug menu.
k). Fix any errors that are reported.
l). Repeat steps j & k until no more errors are reported.
m). Run Performance Analyzer.

2. Create a new database.
a). From the Database Window, select the Tables tab.
b). Click Import Table.
c). Browse to and select the old database, then click Import.
d). Move from tab to tab, clicking Select All.
e). Click Options.
f). Tick Relationships, Menus and Toolbars, and if you have imports
specs, tick that one as well.
g). Click OK.
h). Close, then re-open the database.
i). Compact & Repair the database, then close it.
j). Re-open the database in the normal way (without using the shortcut).
k). Open any code module, and select Compile from the Debug menu.
l). Fix any errors that are reported.
m). Repeat steps j & k until no more errors are reported.
n). Run Performance Analyzer.

If none of that works, come back and we'll see what else we might be able to
try.

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia
 
G

Graham R Seach

Brian,

I responded to your post on Oct 24, but I can't see my response in the
newsgroup, so I thought it wise to repost. The following is what I said:

Brian,

I can find no helpful reference to this issue anywhere, so unfortunately
there are only two things I can think of. Try the first suggestion, and if
that doesn't resolve it, try the second.

1. Decompile the database.
a). Create a Windows shortcut.
b). Right-click the shortcut, and select Properties.
c). In the Target box, you'll see the path to the database.
d). Add the path (enclosed in double quotes) to msaccess.exe to the left
of the database's path, adding a space between them.
e). Add the /decompile switch to the right of the database's path,
adding a space between them.
"path to msaccess.exe" "path to database" /decompile
f). Click OK.
g). Double-click the shortcut to launch the database.
h). Compact & Repair the database, then close it.
i). Re-open the database in the normal way (without using the shortcut).
j). Open any code module, and select Compile from the Debug menu.
k). Fix any errors that are reported.
l). Repeat steps j & k until no more errors are reported.
m). Run Performance Analyzer.

2. Create a new database.
a). From the Database Window, select the Tables tab.
b). Click Import Table.
c). Browse to and select the old database, then click Import.
d). Move from tab to tab, clicking Select All.
e). Click Options.
f). Tick Relationships, Menus and Toolbars, and if you have imports
specs, tick that one as well.
g). Click OK.
h). Close, then re-open the database.
i). Compact & Repair the database, then close it.
j). Re-open the database in the normal way (without using the shortcut).
k). Open any code module, and select Compile from the Debug menu.
l). Fix any errors that are reported.
m). Repeat steps j & k until no more errors are reported.
n). Run Performance Analyzer.

If none of that works, come back and we'll see what else we might be able to
try.

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia
 
B

Brian Bishop

Graham
Thank you very much for your help. Unfortunately pressure of work has
prevented me from yet applying your suggestion (the database is still
working). I will however apply it, and will let you know the result.
 
B

Brian Bishop

Graham

Your option number 2, "create a new database", seems to have done the trick.
I can now use the Performance Analyzer option. Thank you for your help.
 
G

Graham R Seach

Brian,

Glad you got it working. The key was when you said, "...although sometimes
'Compact & Repair' produces a fault."

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia
 

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