Tkinter Treeview to add parent and child rows using insert() with parent and iid options

preview_player
Показать описание
We can add parent and child rows to the Treeview by using parent option. This option will take the value of the iid of other row to became the child of it. By using parent option we can iid value of other node or row to mark the present row child of it.

Here we have added one level of child to second row and then two levels of child to second row.

While using insert method we can add this parent value to the Treeview using parent option.
To keep child node open we can use option open=True. By using open as False open=False we can keep the child node in closed mode and on expand or double click we can open the child window. Double click in parent window will open the child window in headers view mode. In case of Tree view we can click the plus indicator to expand the child view.
#parentchildintreeview #addchildtotreeview #iidofparentchild
Рекомендации по теме
Комментарии
Автор

Thank you
I learn a new thing.
Sir please make video on
How insert Entry box in tkinter teeeview cell.
Thank you

stevemarshall
Автор

I it possible to do this with entryboxes away from the command line. I will really appreciate if you can extend this through entry widget. All in all its a great video

BN-SonOfTheSoil
join shbcf.ru