Add New Database Record With Treeview - Python Tkinter GUI Tutorial #177

preview_player
Показать описание
In this video I'll show you how to add a new record to the database with our treeview app using tkinter and Python.

Adding a record to the database is pretty straight forward, I'll show you how to do it in this video.

After we add a new record, we want to clear the entry boxes and refresh the treeview to reflect the changes. To

do that we'll clear the treeview completely and then requery the database and output the results back to the cleared treeview.

#tkinter #codemy #JohnElder

Timecodes
0:00​​ - Introduction
1:22 - Create Add_record Function
2:06 - Connect To Database
2:27 - SQL INSERT INTO Execute Command
5:26 - Clear Entry Boxes
6:02 - Clear The Treeview Table
7:21 - Query The Database To Treeview Table
8:33 - Conclusion
Рекомендации по теме
Комментарии
Автор

▶️ Watch Entire Tkinter Playlist ✅ Subscribe To My YouTube Channel:
▶️ See More At: ✅ Join My Facebook Group:
▶️ Get The Code

Codemycom
Автор

Hi John, you just have a pair of magic hands, your codes are always simple and clean, easy to follow and understand. Thank you so much for your nice videos. Please keep on sharing goodies with us.

margaretlai
Автор

This series of videos are helping me a lot, im excited how the program will ends

nicolasgabriel
Автор

hi john, it is a wonderful demo. how to add two more buttons "search by" and "sort by"... also how to enter superscript, subscript data like chemical formula.. can you please make a short video?. i know you will receive a large number of comments, but please help. thanks. stay safe

Planetearth
Автор

Hi John, thanks again for sharing your knowledge with the rest of us! The videos are great, but I have a bit of a problem - I am running on a Mac and I can't seem to get the refresh code (that is, the close and re-open the feed from MySQL to reflect the new records) to work and I was wondering if it has anything to do with the fact that I'm running on a Mac. I've checked and re-checked the code, but can't see any issues with it. Anyway, thanks again...

lilytucker
Автор

Great Video! One thing I noticed is that when clicking the add button while the entry boxes are empty, it still adds them to the database and treeview. Is there a way to add a restriction for that?

Albrazi
Автор

Hello everyone,
i'm a new programer i'm following the steps of this series and implementing to my code,
but i'm lost now, i did a method to filter the treeview based on my database records and
i want to export that filtered data to a csv and next PDF file. I searched a lot but unfortunately
i didn't find examples. Hope someone answer me <3

nicolasgabriel
Автор

Hello,
I'm a new programer and i write a code in python and tkinter but, there was a problem that when i do like a button and a for/while loop or time.sleep() the button lag and all the window lag i don't know why
I searched and didn't find anything
I hope you answer me💗

whitebeard
Автор

hi☺☺☺.... how to increment number it without adding it ?

tojoeinstein
Автор

sir how to open new window when we click on a treeview row

surajsharma
Автор

How to perform navigation & routing from one page to another in tkinter?

saransundaresanmadhavan
join shbcf.ru