Hi all,
im having a problem using the dialogresult. I have 2 forms, frm1 and frm2. frm1 is the main form and frm is another window that will popup and ask the user to save. So when the user hits the back button it will return dialogresult to frm1.

here is the code:

Frm1
VB Code:
  1. Dim l_result As DialogResult
  2. l_result = l_frm2.ShowDialog(Me)
  3. 'here l_result is always DialogResult.None

Frm2
VB Code:
  1. Private Sub btBack_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btBack.Click
  2.         If m_settings Is Nothing Then
  3.             DialogResult = DialogResult.Cancel
  4.         Else
  5.             DialogResult = DialogResult.OK
  6.         End If
  7.         If m_Saved = True Then
  8.             Me.Close()
  9.             Me.Dispose()
  10.         Else
  11.             If MsgBox("Exit without saving?", MsgBoxStyle.YesNo, "") = MsgBoxResult.Yes Then
  12.                 Me.Close()
  13.                 Me.Dispose()
  14.             End If
  15.         End If
  16.     End Sub

is the me.dispose causing the problem??