hi, the items in the DropDownChoice come from another part of the
application.  someone could enter the page with the DropDownChoice on
it when there are three items in it but another user could delete two
of them and the first user could refresh the page and ideally it would
automatically select the only available option

when there is functionality that looks like it should be part of the
fabric of the application somewhere in a model or in a component but
i'm putting it on the page somewhere that will not activate in all
situations... i get the feeling that i'm doing something wrong. maybe
i am not

i will put the code in the constructor and will revisit this at a later date

thanks for all your responses

john


On Thu, Aug 28, 2008 at 2:13 PM, James Carman
<[EMAIL PROTECTED]> wrote:
> How are the items in the DDC changing?
>
> On Thu, Aug 28, 2008 at 9:02 AM, John <[EMAIL PROTECTED]> wrote:
>> hi, thanks for your response.  i know i can set the model manually at
>> point of component creation but as i understand it that code won't be
>> executed if the page is redisplayed and the items in the
>> DropDownChoice have changed and it would need to be duplicated each
>> time i need this functionality.  it seems to me that this
>> functionality should be in my custom extension of the component.  i
>> could put such code in the constructor of my component but again it
>> would not be executed when the component is redisplayed.
>>
>> apologies... maybe i have got the wrong end of the stick here...
>>
>> maybe should this code only be executed once, and not again?
>>
>> john
>>
>>
>>
>> On Thu, Aug 28, 2008 at 11:37 AM, Nino Saturnino Martinez Vazquez Wael
>> <[EMAIL PROTECTED]> wrote:
>>> just set the model to what you want selected:)
>>>
>>> John wrote:
>>>>
>>>> hi, when using a DropDownChoice is there a way to have the value
>>>> preselected if there is only one available and the field is required?
>>>>
>>>> i have looked through the code but cannot see any settings that might
>>>> control this, and am stumped trying to work out how to extend the
>>>> control in this way.
>>>>
>>>> john

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to