+void MyFrame::NumericEntry(wxCommandEvent& WXUNUSED(event) )
+{
+ long res = wxGetNumberFromUser( "This is some text, actually a lot of text.\n"
+ "Even two rows of text.",
+ "Enter a number:", "Numeric input test",
+ 50, 0, 100, this );
+
+ wxString msg;
+ int icon;
+ if ( res == -1 )
+ {
+ msg = "Invalid number entered or dialog cancelled.";
+ icon = wxICON_HAND;
+ }
+ else
+ {
+ msg.Printf(_T("You've entered %lu"), res );
+ icon = wxICON_INFORMATION;
+ }
+
+ wxMessageBox(msg, "Numeric test result", wxOK | icon, this);
+}
+
+void MyFrame::PasswordEntry(wxCommandEvent& WXUNUSED(event))
+{
+ wxString pwd = wxGetPasswordFromUser("Enter password:",
+ "Passowrd entry dialog",
+ "",
+ this);
+ if ( !!pwd )
+ {
+ wxMessageBox(wxString::Format("Your password is '%s'", pwd.c_str()),
+ "Got password", wxOK | wxICON_INFORMATION, this);
+ }
+}
+
+void MyFrame::TextEntry(wxCommandEvent& WXUNUSED(event))