[Mono-bugs] [Bug 551716] msgbox with option YesNo is not shown and gives the result no

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Mon Nov 2 08:34:50 EST 2009


http://bugzilla.novell.com/show_bug.cgi?id=551716

User jhmgbl2 at t-online.de added comment
http://bugzilla.novell.com/show_bug.cgi?id=551716#c2





--- Comment #2 from Johannes-Martin Goebel <jhmgbl2 at t-online.de>  2009-11-02 06:34:48 MST ---
This is my old Code which didn't work:
 If ClsGlobal.PromptToSaveChanges AndAlso _frmMain.Listview.HasUnsavedImages
Then
        If MsgBox(GetLang("SaveAllChanges", "Möchten sie alle Änderungen
abspeichern?", Me), MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
          _frmMain.SaveChanges(True, False, Me.Index, UcpB.path, True)
        End If
      End If

This is my new Code:

 If ClsGlobal.PromptToSaveChanges AndAlso _frmMain.Listview.HasUnsavedImages
Then
        If MessageBox.Show(GetLang("SaveAllChanges", "Möchten sie alle
Änderungen abspeichern?", Me), "Save Changes", MessageBoxButtons.YesNo,
MessageBoxIcon.Question, MessageBoxDefaultButton.Button1) =
Windows.Forms.DialogResult.Yes Then
          _frmMain.SaveChanges(True, False, Me.Index, UcpB.path, True)
        End If
      End If

which works.

It seems to me that in other parts of the program msgbox does work. And your
sample works as well!

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list