Hi,

I have a need to dynamicly refresh a dropdown.  I have tried using bindEvent 
for GotFocus, Hit, MouseLeftClick. Using the following code below to refresh 
the choices and keys.

Where courseID = the RegID of the dropdown
def courseChoices(self):
        self.escourse.requery()
        courseDS = self.escourse.getDataSet()
        availableChoices=['<None>']
        keyChoices=[0]
        for row in courseDS:
            availableChoices.append(row['name_1'])
            keyChoices.append(row['pkid'])

        return availableChoices,keyChoices
    
    def _refresh_courses(self):
        self.courseID.Choices = []
        self.courseID.Keys = []
        ch,ky = self.courseChoices()
        self.courseID.Choices = ch
        self.courseID.Keys = ky
        self.courseID.update()

On my system the form locks up on 
self.courseID.Choices = ch

Johnf



_______________________________________________
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907301010.13803.jfabi...@yolo.com

Reply via email to