DropDownChoice and setNullValid()
I am trying to get a DropDownChoice to select either a country or the option any country. searchOptions.add(new DropDownChoice(search-country, countries, countriesRenderer) .setNullValid(true).setRequired(false) // (*) ); With the second line (*) commented out, the drop-down menu initially shows any country Belgium ... Once I select Belgium and submit the form, the any country vanishes forever. That's the what I expect. ... but: with the line (*), I have the behaviour I need, but instead of any country I get an empty string: empty string Belgium ... Meaning, the DropDownChoice does not pick up anymore my entry search-country.null=any country from the .properties file. Any idea how I can get the any country? Thanks, Kaspar - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: DropDownChoice and setNullValid()
Kaspar Fischer schrieb: I am trying to get a DropDownChoice to select either a country or the option any country. searchOptions.add(new DropDownChoice(search-country, countries, countriesRenderer) .setNullValid(true).setRequired(false) // (*) ); With the second line (*) commented out, the drop-down menu initially shows any country Belgium ... Once I select Belgium and submit the form, the any country vanishes forever. That's the what I expect. ... but: with the line (*), I have the behaviour I need, but instead of any country I get an empty string: empty string Belgium ... Meaning, the DropDownChoice does not pick up anymore my entry search-country.null=any country Try search-country.nullValid=any country - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: DropDownChoice and setNullValid()
On 18.03.2008, at 16:47, Kai Mütz wrote: Try search-country.nullValid=any country Thanks, works like a charm! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]