Button callback only works one time due to threading Button callback only works one time due to threading tkinter tkinter

Button callback only works one time due to threading


You should probably start the thread from a launch function, instead of from inside the button command.

Maybe like this:

def launch_cmd(dummy=None):    threading.Thread(target=ocr_callback).start()...ocr_button = Button(root, text='OCR Files', relief='groove', bg='#5D1725',\                    bd=0, width=scaled(20), fg='white', command=launch_cmd, state=DISABLED)