Python Forum
[Tkinter] Closing a window but not the whole program
Thread Rating:
  • 4 Vote(s) - 2.75 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Tkinter] Closing a window but not the whole program
#2
Don't call sys.exit() then. I'm sure tk has a window close method. Maybe something like root.destroy() or frame.destroy().

If that doesn't help, please share some code so we can see what's going on.
Reply


Messages In This Thread
RE: Closing a window but not the whole program - by nilamo - Jan-10-2019, 09:42 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Interaction between Matplotlib window, Python prompt and TKinter window NorbertMoussy 3 541 Mar-17-2024, 09:37 AM
Last Post: deanhystad
  [PyQt] PyQt5 window closing when trying to display a graph bianca 4 1,743 Aug-12-2023, 03:25 PM
Last Post: bianca
Exclamation [Tkinter] Error when closing the main window with destroy TomasSanchexx 1 795 Aug-06-2023, 01:54 AM
Last Post: deanhystad
Question closing a "nested" window with a button in PySimpleGUI and repeating this process Robby_PY 9 13,640 Jan-18-2021, 10:21 PM
Last Post: Serafim
  [PyQt] Received RunTimeError after script concludes, closing Dialog Window (clicking x-out) skipper0802 0 2,577 Oct-09-2020, 09:23 PM
Last Post: skipper0802
  Closing window on button click not working kenwatts275 4 3,812 May-03-2020, 01:59 PM
Last Post: deanhystad
  Running cli program within a wx window? t4keheart 2 2,776 Jan-23-2020, 04:50 PM
Last Post: buran
  tkinter window and turtle window error 1885 3 6,752 Nov-02-2019, 12:18 PM
Last Post: 1885
  [split] Closing a window but not the whole program scriptdrache 1 2,339 Jun-25-2019, 03:43 PM
Last Post: joe_momma
  How to stop a tkinter function, without closing the window? keakins 5 13,100 Jun-29-2017, 11:53 AM
Last Post: keakins

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020