Jorge Godoy <[EMAIL PROTECTED]> writes:
(...)
> It is all working perfectly, except that when I need to come back from the
> database to the GUI it isn't accepting the 'setCurrentText()' command. In
> fact, it accepts it, gives no error, but doesn't change the text in the
> comboboxes.
>
> My code is like this:
>
>
> def dbExams_currentChanged(self, record):
> code = record.value('code').toString()
(...)
> self.cbCode.setCurrentText(code)
I also tried this variation without success:
code = registro.value('code').toString()
for i in xrange(self.cbCode.count()):
if self.cbCode.text(i) == code:
self.cbCode.setCurrentItem(i)
break
> Is there any method to find the index position for some given text that I
> could use to try showing the desired item?
The attempt above was a way to achieve that... I don't know if it is the best
or not, but it didn't work.
--
Jorge Godoy <[EMAIL PROTECTED]>
_______________________________________________
PyKDE mailing list [email protected]
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde