Python Forum
[PyQt] How do I display the DB table I will choose from the QComboBox in QTableWidget - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: GUI (https://python-forum.io/forum-10.html)
+--- Thread: [PyQt] How do I display the DB table I will choose from the QComboBox in QTableWidget (/thread-34500.html)



How do I display the DB table I will choose from the QComboBox in QTableWidget - JokerSob - Aug-05-2021

I have several DB tables and I have written the names of these tables into the combobox, but I cannot call any table I selected from the combobox. In addition, when calling the DB Table, I have a lineedit where I write the date first and a button to perform the operation. Is there any way I can do this?

as an example:

= DB tables =
A, B, C, D ,E

= GUI =
Lineedit
Combobox ( A, B, C, D, E in DB table names )
Button

Tablewidget

By the way, I can assign individual buttons and list them, but it would be nicer to be able to list by selecting them from the combobox. So a separate button for table A - B - C - D - E


RE: How do I display the DB table I will choose from the QComboBox in QTableWidget - Larz60+ - Aug-05-2021

Please show your code.


RE: How do I display the DB table I will choose from the QComboBox in QTableWidget - JokerSob - Aug-05-2021

(Aug-05-2021, 09:43 AM)Larz60+ Wrote: Please show your code.

Ok, I solved the problem. I realized that I made a small mistake... now I can get the result I want to do