[PyKDE] Problem connecting to QDataBrowser.currentChanged

Hans-Peter Jansen hpj at urpla.net
Tue Aug 6 13:54:01 BST 2002


Hi,

attached is a sql example, which stores images in a database. In order
to control its behaviour, I would like to connect to the
currentChanged(const QSqlRecord *) signal. But it results in:

Traceback (most recent call last):
  File "./runform3.py", line 32, in polish
    self.currentChanged)
RuntimeError: Signal has wrong argument types for slot
Traceback (most recent call last):
  File "./runform3.py", line 32, in polish
    self.currentChanged)
RuntimeError: Signal has wrong argument types for slot
Traceback (most recent call last):
  File "./runform3.py", line 32, in polish
    self.currentChanged)
RuntimeError: Signal has wrong argument types for slot
Traceback (most recent call last):
  File "./runform3.py", line 32, in polish
    self.currentChanged)
RuntimeError: Signal has wrong argument types for slot

Signal handler is defined as follows:
    def currentChanged(self, rec):

The question is, how do I specify a const QSqlRecord * parameter 
in my signal handler?

TIA,
  Hans-Peter
-------------- next part --------------
A non-text attachment was scrubbed...
Name: runform3.py
Type: text/x-python
Size: 8354 bytes
Desc: not available
Url : http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20020806/3e502c86/runform3.py
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testform3.ui
Type: application/x-designer
Size: 22481 bytes
Desc: not available
Url : http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20020806/3e502c86/testform3.bin
-------------- next part --------------
use testdb;

#drop table test;
create table test (id integer primary key auto_increment,
                   name varchar(100) not null default '',
                   file varchar(255) not null default '',
                   descr text not null,
                   image mediumblob not null,
                   chgts timestamp);



More information about the PyQt mailing list