首页 > 解决方案 > 错误选项“-options”:必须是 -default、-detail、-icon、-message、-parent、-title 或 -type

问题描述

我想在这个 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()

请问有人可以回答吗

标签: pythontkinteroptionsmessagebox

解决方案


推荐阅读