[pygtk] combobox clear issue

anusha k anuhacks at gmail.com
Thu Apr 9 10:57:30 WST 2009


hi all,
 I am using the glade and pygtk.My entries in the combobox will change
dynamically.But i am not able to clear the combobox
I used both combobox.clear and model.clear.but both of them resulted into
nothing.

My code is as  follows:
         model_groupname = self.combobox_groupname.get_model()
        active_groupname = self.combobox_groupname.get_active()
        model_basedon=self.combobox_basedon.get_model()
        active_basedon = self.combobox_basedon.get_active()


        model_basedon.clear()
        queryParams=[model_groupname[active_groupname][0]]
        res = self.account.account.getAccountByGroup(queryParams)
        for l in range(0,len(res)):
            self.lst_basedon.append(res[l][2])
        for l in self.lst_basedon:
                self.combobox_basedon.append_text(l)
        self.combobox_basedon.set_model(model_basedon)

Can someone what the mistake i have done
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.daa.com.au/pipermail/pygtk/attachments/20090409/e4995d45/attachment.htm 


More information about the pygtk mailing list