def OnSaveAs(self,event): dialog=wx.FileDialog(None,'wxpython notebook',style=wx.FD_SAVE) if dialog.ShowModal()==wx.ID_OK: self.file=dialog.GetPath() self.text.SaveFile(self.file) dialog.Destroy()