Can't reproduce application error in full access

E

eurochris

I have a access runtime file which runs perfectly on my PC where there
is a full version of access. When I run the front end on any PC without
full access it crashes during a search. The search involves requerying
the form after every key stroke. I can't reproduce the error even when
I run access with the /runtime switch. In all other regards the front
end works perfect. I would like to keep the form the same because it
makes it very easy to find records and the users really like the
feature. The error I get is not a runtime error but an application
error. I get that Send Error Report dialog box and the application
crashes out completely. Has anyone ever come across a similar problem
that they know of. I searched the ng before posting and I could only
find one related message but the error was a runtime error which is not
what I am getting at all.

I thought that access runtime was a stripped down version of access but
essentially the same. What I am getting seems to condradict this. Can
anyone help?

Many Thanks.
Chris Kelly
 
A

Alex White MCDBA MCSE

The runtime does completely crash on an unhandled error, every bit of vba
should be wrapped within error code blocks, otherwise you get the issues you
describe.

for the most comprehensive error blocks try the following


private sub cmdmyButton_Click
on error goto Err_cmdmyButton_Click
10 .. some command
20 .. other command
Exit_cmdmyButton_Click
exit sub
Err_cmdmyButton_Click
msgbox "yourformname cmdmyButton_Click " & vbcrlf err.description &
vbcrlf & err.number & vbcrlf & erl()
resume next
end sub

the above code is complete air code and is totally untested.

but what you get when an error happens is what form, what event, error
number, error description, the line number the error happend. you must use
the line numbers at the start of the line as well.

again wrap all you code within error blocks.

hope it helps.
 
E

eurochris

Alex,
Thanks for getting back to me so soon. I checked my code fully and
it is all wrapped in error code. There are no functions called from
within the code either apart from Requery which is called everytime
another character is typed. All forms are referenced as Form objects
before using their methods. I can't understand it. I may change it so
that a full string needs to be typed before requerying but this would
changes the interactive nature of the form works and I'm sure that
users will complain. Do you think there is there anything I may be
overlooking.
Many thanks,
Chris
 
E

eurochris

I will post it soon. Just have to apply all runtime updates first in
case there is something I am missing. Many thanks for your help though.
Chris
 
Top