I have a button that writes output to a file. And checks if the file with that filename already exists. It is supposed to ask the user to override or not? But it is not working. If the user says No, then the program will still override the file.
This is the code to pop up the MessageBox:
if os.path.exists(self.filename.get()):
tkMessageBox.showinfo('INFO', 'File already exists, want to override?.')