CodePudding user response:
First of all, define a function:Def delete_the_line (* args) :
ListBox_1. Delete (first=listBox_1 curselection (), the last=None) # delete listbox choose the contents of the
Then you set the listbox control binding a double-click the mouse events:
ListBox_1. Bind (' & lt; Double - Button - 1 & gt; ', delete_the_line) # after this command refers to double click the mouse, called function delete_the_line, then execute the delete command