Open and Save Dialogs

Mike Driscoll mdriscoll at co.marshall.ia.us
Thu Aug 2 11:22:27 PDT 2007


 

> -----Original Message-----
> From: Ian Mallett [mailto:geometrian at gmail.com] 
> Sent: Wednesday, August 01, 2007 10:48 PM
> To: wxpython-users at lists.wxwidgets.org
> Subject: Open and Save Dialogs
> 
> Hi,
> 
> I've been looking around for a file opener and a file closer 
> dialog.  wxPython appears perfect for the job.  The demo 
> FileDialog.py includes both.  However, the save/open dialogs 
> launch from another screen.  What I'd like is for when in my 
> code I do something like: 
> 
> import save, open
> def main():
>   filename = save.main()
>   #later...
>   filename = open.main()
> 
> two modules, save and open, will run their corresponding dialogs.  
> 
> This is my first wxPython project, but I took an attempt at 
> making open and save functions (attachments).  They run, but 
> they still launch from the same table.  Can anyone help?  
> Thank you very much. 
> 
> Ian
> 

I must be missing something here. Can't you just use one panel with 2
buttons? One button opens a file and the other button save? Or better yet,
create a menubar with Open and Save options and have them launch the
wx.FileDialog methods with the appropriate flags?

Mike





More information about the wxpython-users mailing list