Jun-27-2022, 05:20 PM
hello,
i have a little question to my code. i have 2 files in the same folder, script 1 and script 2
code in script 1:
the second time i click nothing happens.
it would be nice if the second time you click the window opens again
is this somehow possible? I sit at the problem already some days and come on no solution
I thank you first of all
achim1024768
i have a little question to my code. i have 2 files in the same folder, script 1 and script 2
code in script 1:
from tkinter import * ws = Tk() ws.geometry('400x300') ws.title('PythonGuides') ws['bg']='#5d8a82' f = ("Times bold", 14) def nextPage(): import page2 Label( ws, text="This is First page", padx=20, pady=20, bg='#5d8a82', font=f ).pack(expand=True, fill=BOTH) Button( ws, text="next page", font=f, command=nextPage ).pack(fill=X, expand=TRUE, side=LEFT) ws.mainloop()and script 2
from tkinter import * ws = Tk() ws.geometry('400x300') ws.title('PythonGuides') ws['bg']='#ffbf00' f = ("Times bold", 14) Label( ws, text="This is Second page", padx=20, pady=20, bg='#ffbf00', font=f ).pack(expand=True, fill=BOTH) ws.mainloop()my question is, why can i only click next page once?
the second time i click nothing happens.
it would be nice if the second time you click the window opens again
is this somehow possible? I sit at the problem already some days and come on no solution
I thank you first of all
achim1024768