-
I have a program that works great on most machines, but on a very few, when the exe is run, it gives an "unexpected error" and shuts down. What is causing this, and what can I do about it? Could some of the dependencies be out of date? I'm wondering if it's a Windows version thing (9x vs NT)
-
<?>
Code:
'add an error handler to it and in each sub put
'this line at the top of each sub
'after the Command_click or whatever event
OnError goto errHandler:
'At the bottom of each sub (just above end sub)
'put this
errHandler:
'get error source and description
Dim Msg$
' If an error occurs, construct an error message
'hardcode the error number for test purpose
If Err.Number <> 0 Then
Msg$ = "Error # " & Err.Number & " was generated by " _
& Err.Source & Chr(13) & Err.Description
MsgBox Msg$
End If
' and then run it on a machine that crashes and see what
'error it generates.