How to clear/delete the contents of a Tkinter Text widget?

后端 未结 7 1318
谎友^
谎友^ 2020-12-09 01:05

I am writing a Python program in TKinter on Ubuntu to import and print the name of files from particular folder in Text widget. It is just adding f

7条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-09 01:45

    A lot of answers ask you to use END, but if that's not working for you, try:

    text.delete("1.0", "end-1c")

提交回复
热议问题