The IDE will show you the line from which the exception is raised. If
you could post a little more code and identify the offending line, we
could do more than speculate.
Charles Yeomans
On Apr 28, 2008, at 6:46 PM, David Stein wrote:
> In a KeyDown event, I want to call a method which will close the
> current window (Window1) and display another window (Window2). When I
> try to implement this, I get a NilObjectException. I think the
> problem is that my NextWindow method is called and then the code in
> the KeyDown event handler keeps executing. In the following example,
> if i=6 I don't ever want to see the "Got here." MsgBox. I may be
> using the term incorrectly, but what I think I need is a way to call a
> method synchronously. Can anyone help?
>
> David
>
> in the KeyDown event handler for Window1:
>
> If i = 6
> NextWindow
> End If
> MsgBox "Got here."
> i = i + 1
>
> The NextWindow method:
>
> Window2.Visible=True
> Window1.Close
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>
|