Edit: let me include my code so I can get some specific help.
import Tkinter
def goPush():
win2=Tkinter.Toplevel()
win2.geometry( 400x50 )
Tkinter.Label(win2,text="If you have prepared as Help describes select Go otherwise select Go Back").pack()
Tkinter.Button(win2,text="Go",command=bounceProg).pack(side=Tkinter.RIGHT,padx=5)
Tkinter.Button(win2, text="Go Back", command=win2.destroy).pack(side=Tkinter.RIGHT)
def bounceProg():
d=1
print d
root=Tkinter.Tk()
root.geometry( 500x100 )
Tkinter.Button(text= Go , command=goPush).pack(side=Tkinter.RIGHT,ipadx=50)
root.mainloop()
所以当你运行程序时,它会打开一个窗口,上面写着Go。然后Go打开一个窗口,询问您是否阅读了帮助(我没有在这个代码示例中包含),并提供Go Back(返回)和Go。当您选择Go时,它会调用一个打印1的函数。在它打印1之后,我希望窗口关闭,返回到包含Go按钮的原始窗口。我该怎么做这样的事?