Dec-18-2018, 08:37 AM
(Dec-17-2018, 07:15 PM)Axel_Erfurt Wrote: Ok, it creates a database with no entries.After the the comboBoxes are filled correctly it will saved in QtableWidget in the database.
If there are entries then you want to fill the ComboBoxes? Or the table?
I have a DB Viewer on github that shows how to load a database into QTableWidget
There are entries in the database in QtableWidget.
The columns are product_id,product_name,inventory_received,starting_inventory,product_price and values for each rows.The content of my database user.db is shown in the file but I intended to add price.
I have three comboboxes
first comboBox is product id
second comboboxes is product_name
third comboBoxes is price.
I want the second Combobox to list all the product.That is working perfectly.
I want the first comboBox to reflect the product_id of the selected product_name.
I want the third comboBox to reflect the price of the selected product_name.
How can I achieve this behavior?I have checked out your work on GitHub.But, I am not getting the database to work on my side even when add a database on my system into the path.