Read about models [1] and the DDC example [2,3]. Considering that this
is the N-th posting with exactly the same question and you already
know Nabble, how about using the search facilities [4]?

Martijn

[1] http://cwiki.apache.org/WICKET/working-with-wicket-models.html
[2] http://wicket.apache.org/exampledropdownchoice.html
[3] http://cwiki.apache.org/WICKET/dropdownchoice-examples.html
[4] 
http://www.nabble.com/forum/Search.jtp?query=dropdownchoice+model&local=y&forum=13974&daterange=0&startdate=&enddate=


On 3/24/08, tdelesio <[EMAIL PROTECTED]> wrote:
>
>  Is it possible to use two objects in a dropdown choice.  For instance in the
>  below code I want to use the class Pizza for the model of the form but load
>  it with a list of toppings.  When I do it the model of the form is getting
>  set to Topping when I expect it to be Pizza.  Thanks for the help.
>
>  public class Pizza
>  {
>
>   private String selectedTopping;
>   private String name;
>  }
>
>  public class Toppings
>  {
>   pirvate int id;
>   private String name;
>  }
>
>  List<Toppings> toppingList = some list from a databae....
>
>  final DropDownChoice comboChoiceDropDown = new DropDownChoice(
>                                                 "selectedTopping", new 
> CompoundPropertyModel(new Pizza()),
>  toppingList,  new ChoiceRenderer("lid", "name"));
>
>
>  --
>  View this message in context: 
> http://www.nabble.com/Dropdown-Choices-tp16259995p16259995.html
>  Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: [EMAIL PROTECTED]
>  For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.2 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.2

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

Reply via email to