wxPython - Simple implement (for Newbie)

DP pennedinil at excite.com
Thu Dec 12 08:06:32 EST 2002


"Steve Hunt" <steve at pSoPgAgMle.org> wrote in message news:<1039613733.5510.0 at dyke.uk.clara.net>...
> > - how do I get just the wxChooseDir (sp?) control to pop up, and the
> > result to be assigned to a variable?
> 
> from wxPython.wx import *
> chooser = wxDirDialog(None)
> if chooser.ShowModal() == wxID_OK:
>     choice = chooser.GetPath()
>     print choice
> else:
>     print "Cancelled"
> 
> > - How do I get a dialog box to come up where user can type in notes
> > and I assign the same to a string?
> 
> Look at the docs for wxMessageDialog, wxTextEntryDialog,
> wxSingleChoiceDialog etc.  Calling them will be similar to
> the directory dialog.
> 
> -- Steve

Thanks, just what I was looking for. I ought to be able to figure the rest out.

Dinil



More information about the Python-list mailing list