Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/324.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python “坏选择”-选项";:必须为-default、-detail、-icon、-message、-parent、-title或-type_Python_Tkinter_Options_Messagebox - Fatal编程技术网

Python “坏选择”-选项";:必须为-default、-detail、-icon、-message、-parent、-title或-type

Python “坏选择”-选项";:必须为-default、-detail、-icon、-message、-parent、-title或-type,python,tkinter,options,messagebox,Python,Tkinter,Options,Messagebox,我想在此showinfo消息框中插入选项 from tkinter import * from tkinter import messagebox root =Tk() root.title("Messaging box") def popup(): messagebox.showinfo("Title","Hello World!",options = ['got it!,no']) Button(root,text = &

我想在此showinfo消息框中插入选项

from tkinter import *
from tkinter import messagebox

root =Tk()
root.title("Messaging box")
def popup():
    messagebox.showinfo("Title","Hello World!",options = ['got it!,no'])
Button(root,text = "Popup",command = popup).pack()


root.mainloop()

请有人清楚地回答
消息框。showinfo
没有该选项,所以不要使用它。我认为
messagebox
不可能实现您想要的功能,您必须使用
Tk
Toplevel