Well i did look at that, but the thing is that i'm using the Value as holder of an ID number.
In the MyScreen.java I load in values used in the MyScreen.vm from a database... And as I need the ID numbers of those values when I later associate the selections with my profile, I can't leave them unset. Unless im wrong and that when it return the values it only sends along those who have been selected? /martin -----Original Message----- From: Ben Gidley [mailto:[EMAIL PROTECTED] Sent: 4. juli 2004 11:43 To: Turbine Users List Subject: Re: Penguin extension... Martin, You can figure out which one(s) are selected by used the getValues function on the field object. A helper function could be useful - (there already is one for Checkboxes/radio buttons). I have added one to CVS for penguin - I will put out a new version in a few days - once I have checked for side effects. The code is private static final String SELECTED = "selected=\"selected\""; /** * Returns the HTML attribute for selected within an option group * @param value * @return */ public String isSelected(String value) { // We can always uses the array as values is always filled by validation for (int i = 0; i < values.length; i++) { if (values[i].equals(value)) { return SELECTED; } } return ""; } Ben Martin Wendel wrote: >Hey guys, i think the penguin tool is nice, however it is missing the value >of "selected" for options in select lists... > >I thought about just adding a Selected to the Option class, but I'm not sure >about what else to do. Any help here? > >/Martin > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
