On Mon, Jul 27, 2009 at 5:30 AM, Paul McNett<[email protected]> wrote:
> Ed Leafe wrote:
>>       Paul, I'm wondering - could we trap this particular error, set a flag
>> in the object, and then add this to the end of the event loop using a
>> setAfter call? The flag would enable us to avoid infinite loops if an
>> attempt to set an invalid value was made, but would avoid erroring out
>> because of the wrong event order.
>
> The problem stems from setting listbox.Value before listbox.Choices and
> listbox.Keys are set?

No. I have the problem even considering / respecting that.

This case maybe special because the form is loaded from a cdxml file.
Note that properties are not being set in the class designer (as per
my email above).

In this case dropdownList properties are being set in the afterInitAll
cdxml form method. The code is:

def afterInitAll(self):
        _valueListProvider = self.Application.getAppInfo('valueListProvider')
        vlKeys, vlChoices = 
_valueListProvider.getKeysAndChoices('contact_title')
        dropDown = self.getObjectByRegID("dlTitle")
        dropDown.DataSource="contact"
        dropDown.DataField="title_id"
        dropDown.Keys = vlKeys
        dropDown.Choices = vlChoices
        dropDown.ValueMode="Key"      # if both commented runs ok - but not
in 'key' valueMode
        dropDown.Value = vlKeys[0]       # if both commented runs ok - but
not in 'key' valueMode


I started to think the problem might not be order, but comming from
when the bizobj. So I made sure the bizobj is previously created (in
the createBizobj cdxml form method). This had no success.

Miguel


_______________________________________________
Post Messages to: [email protected]
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/[email protected]

Reply via email to