def OnCmdSave(self, cmd, code):
        flags = win32con.OFN_OVERWRITEPROMPT 
        dlg = win32ui.CreateFileDialog(0, None, None, flags, "Text Files (*.txt)|*.txt||", self)
        dlg.SetOFNTitle("Save Results As")
        if dlg.DoModal() == win32con.IDOK: