Hi Andrew, Thanks for your help. I will consider using the converter as my code is Long, and will read the wiki page you sent to me but the wired thing is that it works sometimes and doesn't work in other times
any way thanks for your help. On 11/6/07, Andrew Robinson <[EMAIL PROTECTED]> wrote: > > Is your "code" a string? > > The converted value of the submitted value has to equal one of the > values of the select items. The select item values are *NOT* converted > (this was an old bug in myfaces that didn't follow the specification). > > So if you build your select objects in a backing bean, you have to set > the value to the exact same value as what the select item control will > convert to. > > So if there is no converter on your selectOneMenu, then the converted > value will be a string -- therefore your select item values must be > strings too. > > If you convert the user values to Integer, then the values on the > select item values must be Integer as well. > > More info: > > http://wiki.apache.org/myfaces/Tomahawk_1.1.4_to_1.1.5 > > On 11/5/07, Ali Abdel-Aziz Ali <[EMAIL PROTECTED]> wrote: > > Hi All, > > > > I have a strange problem. > > I'm using group radio buttons inside the myfaces dataTable and its > working > > properly . > > > > but I have faced a strange error today which is: > > when I "view all" the recorders by pressing on "view All" button (fire > > action that load all records from database and draw them inside the > > dataTable) I can select any row I want by choosing the radio button in > front > > of it. and then can do any action (Edit, Delete) I want. > > > > But when I make filter on the returned records by entering some value to > > filter with the returned result is correctly matching the search > criteria > > but the problem arises when I try to edit one row from the returned rows > I > > keep getting [ myRadioID : value is not a valid option] > > > > this have strange scenario that happen with; that is: > > suppose we have the following records after pressing on view all button > > _____________________________________ > > | index | Code | Name | > > |_______|__________|___________________| > > | 1 | 10 | Ali | > > |_______|__________|___________________| > > | 2 | 12 | Ali_Ahmed | > > |_______|__________|___________________| > > | 3 | 13 | DataTable | > > |_______|__________|___________________| > > | 4 | 15 | Radio Button | > > |_______|__________|___________________| > > | 5 | 17 | Data Records | > > |_______|__________|___________________| > > > > any record of the the above records can be selected by choosing the > radio > > button in front of it and can be edited for example. > > > > but if you make some filter on the Name for example searching for any > name > > starting with "Ali" > > you will got the following records displayed: > > _____________________________________ > > | index | Code | Name | > > |_______|__________|___________________| > > | 1 | 10 | Ali | > > |_______|__________|___________________| > > | 2 | 12 | Ali_Ahmed | > > |_______|__________|___________________| > > > > if you tried to select any row to edit it will be selected properly with > no > > problem and can be edited after pressing on edit button. > > > > but if you tried to search for any Name starting with "Data" you will > got > > the following records > > _____________________________________ > > | index | Code | Name | > > |_______|__________|___________________| > > | 1 | 13 | DataTable | > > |_______|__________|___________________| > > | 2 | 17 | Data Records | > > |_______|__________|___________________| > > > > > > which will produce [myRadioID : value is not a valid option] when you > try to > > select any row of them > > > > > > my explanation for this is that all records that will appear in the > filtered > > table with the same row index as in view all table will be editable with > no > > problem so the case with "Ali" , and "Ali_Ahmed" records as they appear > in > > the same row index so no problem arise when selecting any one of them. > > > > but a problem will arise in the case of "DataTable", and "Data Records" > > records because they appear in row index different than the one they > appear > > in view all table. > > > > > > -- > > Ali Abdel-Aziz > > http://www.aliabdelaziz.com > -- Ali Abdel-Aziz http://www.aliabdelaziz.com

