OK Cancel message box : Dialog : Tkinker PYTHON TUTORIALS


PYTHON TUTORIALS » Tkinker » Dialog »

 

OK Cancel message box


OK Cancel message box
from Tkinter import *

import tkMessageBox

def protocolhandler():
    if tkMessageBox.askokcancel("Exit""Wanna leave?"):
        if tkMessageBox.askokcancel("Exit""Are you sure?"):
            if tkMessageBox.askokcancel("Exit""Really?"):
                root.destroy()
root = Tk()
root.protocol("WM_DELETE_WINDOW", protocolhandler)
root.mainloop()



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


PYTHON TUTORIALS

 Navioo Tkinker
» Dialog