G
Glyn Meek
I have removed all the non relevant parts from the code with which I am
having problems, and this is the essence of it...
Dim frm As New EditContact
' LOAD UP THE DISPLAY FOR THE SELECTED CONTACT
frm.LoadData(MyContact, myLabel(currentfield))
' DISPLAY THE FORM
frm.ShowDialog()
' DETERMINE WHICH BUTTON WAS PRESSED TO EXIT THE CONTACT SCREEN
frm.GetData(ButtonPressed)
Me.Close()
I call the 'frm' to do just display some information (although at a later
date it will do much more), and on return I just want to close the calling
form without doing anything else, and return to the one that called it. (In
the actual code, the 'me.close' is surrounded by an IF statement dependent
on the value of ButtonPressed).
The me.close does NOT WORK in this example. Using the debugger, it just
merrily flies by and keeps going, NOT closing the form at all. The only way
I can get it to work is by clicking the 'OK' button on this 'returned to'
form, but the ONLY code in the click handler for the OK button is me. close!
It would seem that the form to which I return does not recognize the
me.close until an event has been triggered!
What am I doing wrong, or missing out here? Can anyone help???? I am not a
newbie at vb.net cf stuff by any means, but this one is baffling to me!
Regards and thanks
Glyn Meek
having problems, and this is the essence of it...
Dim frm As New EditContact
' LOAD UP THE DISPLAY FOR THE SELECTED CONTACT
frm.LoadData(MyContact, myLabel(currentfield))
' DISPLAY THE FORM
frm.ShowDialog()
' DETERMINE WHICH BUTTON WAS PRESSED TO EXIT THE CONTACT SCREEN
frm.GetData(ButtonPressed)
Me.Close()
I call the 'frm' to do just display some information (although at a later
date it will do much more), and on return I just want to close the calling
form without doing anything else, and return to the one that called it. (In
the actual code, the 'me.close' is surrounded by an IF statement dependent
on the value of ButtonPressed).
The me.close does NOT WORK in this example. Using the debugger, it just
merrily flies by and keeps going, NOT closing the form at all. The only way
I can get it to work is by clicking the 'OK' button on this 'returned to'
form, but the ONLY code in the click handler for the OK button is me. close!
It would seem that the form to which I return does not recognize the
me.close until an event has been triggered!
What am I doing wrong, or missing out here? Can anyone help???? I am not a
newbie at vb.net cf stuff by any means, but this one is baffling to me!
Regards and thanks
Glyn Meek