On Saturday, September 14, 2013 9:46:26 AM UTC+2, M. Venkateswara Rao wrote:
>
>    final ChosenListBox teamChosen = new ChosenListBox(true);
>         teamChosen.getElement().setId("data");//multiple
>         // init options for teamchosen
>     String[] teams = new String[] {
>               "Dallas Cowboys", "New York Giants", "Philadelphia Eagles", 
> "Washington Redskins",
>               "Chicago Bears", "Detroit Lions", "Green Bay Packers", 
> "Minnesota Vikings",
>               "Atlanta Falcons", "Carolina Panthers", "New Orleans 
> Saints", "Tampa Bay Buccaneers",
>               "Arizona Cardinals", "St. Louis Rams", "San Francisco 
> 49ers", "Seattle Seahawks",
>               "Buffalo Bills", "Miami Dolphins", "New England Patriots", 
> "New York Jets",
>               "Baltimore Ravens", "Cincinnati Bengals", "Cleveland 
> Browns", "Pittsburgh Steelers",
>               "Houston Texans", "Indianapolis Colts", "Jacksonville 
> Jaguars", "Tennessee Titans",
>               "Denver Broncos", "Kansas City Chiefs", "Oakland Raiders", 
> "San Diego Chargers"};
>         for (String team : teams) {
>           teamChosen.addItem(team);
>         }
>         teamChosen.setPlaceholderText("Choose your favourite teams");
>         root.add(teamChosen,20,0);
>         teamChosen.setMaxSelectedOptions(3);
>

ChosenListBox extend ListBox so you can loop from 0 to getItemCount and 
check isItemSelected and then getItemValue.
Or you can use ChosenListBox's getValues(): 
https://github.com/jDramaix/gwtchosen/blob/66c4ffc83a7ad53de8ee3f9956126bbe8abef32d/plugin/src/main/java/com/watopi/chosen/client/gwt/ChosenListBox.java#L313
 

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to