PDA

View Full Version : How to connect QLineEdit to add to SQLite db? PyQt



joshfokis
8th June 2013, 16:28
I am new to both python and pyqt. I am not sure if there is a way to have the QLineEdit submit directly to the db when a pushbutton is selected and if so is it possible to get an example. I can provide a demo code I have if that would provide any help? Any help is appreciated.

Santosh Reddy
9th June 2013, 00:08
I don't know much about PyQt, but if you know how to connect a signal to a slot this should be a simple and straight forward thing to do, just connect the clicked signal of pushbutton to submit slot of the db or other custom slot to call submit

joshfokis
9th June 2013, 04:16
Thanks for the reply I think I might have figured it out. I won't be able to test it out until later. I have been reading several documents and I have been confused with the QDataWidgetMapper. I think that is my key to connect everything. If I cannot get it I will post more of the code I have and what I have tried.