Af:selectOneChoice not showing appropriate value selected

Hi All,
I am trying to follow this tutorial
http://gergerconsulting.blogspot.com/2007/03/programmatic-selectonechoice-example.html
to populate my selectOneChoice control with dynamic values (populated in a list from my database). The control does show the correct values in the list. But it does not show the appropriate value (of my valueObject.fieldValue) as selected one.
My selectOneChoice is bound to the yesNoListComponent (of type oracle.adf.view.faces.component.core.input.CoreSelectOneChoice)
<af:selectOneChoice binding="#{myManagedBean.yesNoListComponent}">
               <f:selectItems value="#{myManagedBean.yesNoList}"/>
</af:selectOneChoice>
yesNoList is being populated as following :
for (Iterator it = returnList.iterator(); it.hasNext();) {
                         LookupPropertyVO vo = (LookupPropertyVO) it.next();
                         javax.faces.model.SelectItem si = new SelectItem();
                         si.setLabel(vo.getLookupValue());
                         si.setValue(vo.getLookupValue());
                         initList.add(si);
and it shows the values correctly on the jspx page.
Problem is, in my managed bean after populating the valueObject from the backend
I do the setValue on yesNoListComponent to give it the correct value so that the jspx page shows that value selected when the page is rendered.
yesNoListComponent.setValue(myValueObject.getYnFieldValue());
But no matter what the value of ynFieldValue is (yes or no), the selectOneChoice control always shows "no" selected.
Any help would be appreciated,
Thanks,
Robin

Hi Frank,
I would appreciate if you could provide a code snippet for your suggestion.
Isn't the following code already doing what you suggested:
yesNoListComponent.setValue(myValueObject.getYnFieldValue());
(given the fact that "yesNoListComponent" is a non-static field in my managed bean)
Are you suggesting I should do an explicit :
myManagedBean.getYesNoListComponent.setValue(myValueObject.getYnFieldValue());
Also in the jspx,
I am not sure what else I could do other than the following snippet to make sure the managedbean.yesNoListComponent value is picked up by the view
<af:selectOneChoice binding="#{myManagedBean.yesNoListComponent}">
<f:selectItems value="#{myManagedBean.yesNoList}"/>
</af:selectOneChoice>
Sorry I am just revisiting this problem after switching to Spring MVC at my day-time job, so my JSF concepts are rusting out a little bit..may be I am just not getting something too obvious.. please provide some snippet showing what you are suggesting..

Similar Messages

  • SelectOneChoice not showing all values from database

    Hi!
    I have to put a list of values in my select one choice. When I do the query in database, all the values are selected. But, with the same query on JPQL, the select on choice do not show all values in database. Anyone can help me, please?
    P.S.: I am using SelectOneChoice with SelectItems, in JDeveloper 11g
    Code:
    <af:selectOneChoice id="selAction" value="#{row.idCmd}"
    unselectedLabel="&lt;Selecione>">
    <af:forEach var="alertTypeNode"
    items="#{bindings.actionFindAll.iteratorBinding.allRowsInRange}">
    <af:selectItem value="#{alertTypeNode.dataProvider.idCmd}"
    label="#{alertTypeNode.dataProvider.nmCmd}"
    id="si1"/>
    </af:forEach>
    </af:selectOneChoice>

    In your page binding check the rangesize setting for the executable you use - set it to -1.

  • Report similar to MC$4 that does not show absolute values

    Hi all,
    We need a report similar to Report similar to MC$4 which has the same drilldown capabilities but does not show absolute values, and instead shows the proper (actual) values.
    Or if its possible to change something in the MC$4 report to show the actual values and not the absolute.
    Thanks in advance!
    George

    HI
    Your input criteria should contain all plant numbers and the period to be analyzed.  Execute the report and then select:  Plant Analysis\Export\Transfer to XXL\Deselect all options and tick Plant, Storage Location and Month.  Follow the options to export to Excel.  Report will be based on Plant, Storage location and Month.
    Regards

  • Filters not showing up values

    Hi Gurus,
       I am working on some reports in WAD.
       I have characteristic "Region" which has 4 values like EAST,WEST,SOUTH,NORTH. This is a User Entry so I created a variable for this and it shows the values with check boxes beside it when you click on the variable entry screen input help. Once I execute the query the result is displayed. When I click on the Filter ICON on the Navigation Block for REGION it is not showing the Values for this region but just shows only 4 check boxes.
    This Characteristic doesnot have master data. It is displaying the KEY values.
    For the characteristics which Master Data it is showing the values both in Varaible selection screen and also in Filter Selections.
    Please update me with a solution.
    Thanks,
    Raj

    have you tried replacing it with the file essbase.bak_startup file, instead of the older essbase.sec file?
    If you check your app folders you will still be able to see the cubes you had created its just that Essbase can't pull those up with the older .sec file.
    The essbase.bak_startup file is always updated everytime the Essbase server is started up.
    Be sure to take a backup of the file before starting up the server again.
    The reason your essbase.sec and essbase.bak files are both corrupt is because when you first discovered that the essbase.sec file is corrupt it was when you started the server up.
    What you need to keep in mind if the machine which holds the essbase server shuts down abruptly or crashes (which usually leads to the situation you are in) is to never start up the Essbase server right away, as you may have a corrupt essbase.sec file, and if you start up the server without taking a backup of the essbase.bak file you may risk corrupting the essbase.bak file as well.
    This is because at start up the essbase.bak file gets replaced with the essbase.sec file.
    let me know if this works.
    Regards,
    Anindyo

  • Using transactio code to execute a report does not show default value

    Hi all ,
          I have given a default value of a field on my selection-screen by initialization in a hr report .
    I am using PNP database and default selction-screen in hr report category .
    While the report is working fine while executing directly , It is not showing default value when executed through a transaction code .
    Can any body tell why it is so ?
    Thanks & regards
    Sun

    Did you create the transaction as a report transaction?
    Rob

  • OBI columns not showing distinct values.

    Hi,
    Please help me out with the below issue.
    I have a colulmn called Product Type. Same column is been pulled into many subject areas. In one of the subject area the column when checked for all product types, it is not showing distinct values, instead it displays multiple rows of sinlge value. Whereas in other subject areas it dsiplays distinct values.
    So please help me out on this issue.
    Thanks,
    Rajesh S

    Hi,
    I don't think it's not an issue with not selecting "Select Distinct Value" checkbox .. because same column pulled into to other subject areas working fine. But here also sometimes it shows correct distinct value and sometimes all values(Duplicate values).
    Thanks,
    Rajesh.

  • Query is not showing the values - authentication error

    Hi,
    After running a query it is not showing the values and showing <b>"You do not have the authorization for the selected component."</b>
    Diagnosis
    You do not have the authorization for the selected component.
    System response
    The selected component cannot be edited.
    Procedure
    lease speak to the person responsible for authorization, if you require authorization for the editing of this component. The function is protected by the object "Business Explorer - components" with the following fields:
    InfoCube ZPLAYOPPT
    Type of a component REP
    Component PLAYBOOK_OPPT_1
    Activity 16
      Notification Number BRAIN 800 
    <b>Can u pls tell me the solution.</b>Thanks and Regards,
    Giri.

    Go to SU01, look at your authorization profile for which roles you are given. Then, go to PFCG and check out the roles and how they are defined. It is possible that you are not authorized to view application area, infocube, certain characteritics etc.
    Hope this helps,
    Regards,
    Petter

  • ME23n , Does not shows the values correctly in print preview

    Hi,
    When viewing a PO using ME23n , it does not shows the values correctly in the print preview.
    For example;
    This is the vendor & its address.  (check attached image img1.jpg)
    ZERANDIB BUSINESS APPLIANCES
    Number-122/A
    PO BOX 41,112,REID AVENUE
    COLOMBO-04
    When displaying the print preview, it shows only some parts of the above address
    Shows only; (check attached image img2.jpg)
    ZERANDIB BUSINESS APPLIANCES
    PO BOX 41,112,REID AVENUE
    These values are getting from a table called LFA1. I have checked that table & in that table all the values exists correctly.
    I have noted issue is with, having only a single word. (If address or name having only a single word, that is without spaces, it will not going to show in the print preview) -
    In the above example, it is not showing Number-122/A and  COLOMBO-04 (Its a single word. No spaces there)
    If its like --> Number - 122/A   &  COLOMBO - 04 ,  then it will display in the print preview correctly (where there are spaces after - mark)
    check img3.jpg
    If its having more than one word, then it will display correctly in the print preview.  As below;
    ZERANDIB BUSINESS APPLIANCES
    Number - 122/A
    PO BOX 41,112,REID AVENUE
    COLOMBO - 04
    If its 2 or more words, it shows correctly.
    If its 1 word, then its not showing!
    Why it is happening like that? Any ideas how to resolve this issue?
    regards.
    zerandib

    It turns out that this problem went away after the program crashed.  Everything seems to be working well now.

  • PO not showing committment value

    Hi All,
    I am an FI consultant. We have a issue where PO is not showing committment value. Could you please sugget what can be the possible reason.
    Regards
    Deepak

    Hi All,
    further to add this:-
    Our PO value is 815525 GBP & invoice value is 744707.52 GBP.
    our PO qty is 1 & invoice qty is 3.
    Please help.
    Regards
    Deepak

  • PO not showing commitment value

    Hi All,
    We have one issue where PO is not showing committment value. Could you please guide whether this can be becasue of any problem in WBS element or cost element.
    Please suggest.
    Reagrds
    Deepak

    Hi Deepak
    1. Check if Commitment Management is active in Contr Area (OKKP)
    2. Check if Commitment mngt is active in Project profile / WBS element
    3. There is a program for Int Orders, RKANBU01 which updates missing commitments for Int Orders.. Its called RECONSTRUCT AVAILABILITY CONTROL
    See if RKANBU01 or similar program is there for WBS also
    Br, Ajay M

  • TS2978 I have pictures that will not show until I select them. They show a blank square before selection.

    I have pictures that will not show until I select them. They show a blank square before selection. Can anyone advise me how to fix it?

    Open View Options for the folder in which the picture resides; the Desktop counts as a folder for this purpose.
    In the View Options window, checkmark the item "Show icon preview".
    Note that this setting is not global; it affects only the folder for which it is set.

  • User exit variable I_STEP=1 does not show default value WebI selection scr

    Hello,
    We have a BW query with a user exit variable. We have written user exit code under I_STEP = 1 so that the default value for the field is displayed on the selection screen to the user. Works very well on the BW side.
    We based a universe on top of the query and then created a WebI report.
    When the WebI report is executed the default value is NOT seen on the selection screen,
    Note:
    1. If the user exit variable is optional and we execute the report, the default value is NOT seen on the selection screen. However if the report is executed without entering any value for the field the logic under I_STEP = 1 is picked up and the report gets the correct output
    1. If the user exit variable is mandatoryand we execute the report, the default value is NOT seen on the selection screen. The user now has to enter the value for the field.
    The scheduled reports will work in case of optional user exit variable.
    However this amounts to loss of functionality.
    Is this a known bug?
    Is there a way to display default values based on user exit variables on the WebI selection screen?
    Kindly advice. Btw we are on XI 3.1 SP3
    Rgds
    Edited by: Anup Deshmukh on Jun 29, 2010 11:13 PM

    OSS Note 1285993 - "Support of Customer Exit Variables from BEx query into WebIntelligence via OLAP universe"  deals with this issue and has deemed it out of scope for XI 3.1 SP3.
    Rgds

  • Calendar Year variable is not showing listed values

    Hi,
    I have a query which I am running based on the standard variable ( 0CALYEAR ) input. When I run first time it shows the list of values in the selection editor and displays the result. But after executing when I am trying to change filter values in the output, it doesn't show list values as well if I enter manually, I am not getting the result. I am getting out put no data available....
    I created new variables on 0CALYEAR info object, but same problem. My query structure is
    In rows I just defined Calendar Year / Month ( so that I can get all months for that user entered Year ).
    In Columns I defined one Key Figure.
    Thanks
    Ganesh Reddy.
    Edited by: Ganesh Reddy on Mar 8, 2012 8:39 AM

    Problem is resolved my self. Removed 0CALYEAR from Char Restrictions to Default.
    Thanks
    Ganesh Reddy.

  • SelectOneMenu not showing bean value

    Hello,
    I have a simple h:selectOneMenu component that does not show the correct value from the backing bean. Here's the relevant code snippet:
    <h:outputText value="Has the site been inspected?: " />
    <h:selectOneMenu id="siteInspected" value="#{adoptRequestReviewHandler.currentAdoptionRequest.siteInspected}">
         <f:selectItem itemValue="n" itemLabel="No" />
         <f:selectItem itemValue="y" itemLabel="Yes" />
    </h:selectOneMenu>
    //the h:outputText tag (below) is just to see if the the correct value is in the bean
    <h:outputText value="#{adoptRequestReviewHandler.currentAdoptionRequest.siteInspected}" />The h:outputText component correctly displays the bean's siteInspected value--either y or n--but the h:selectOneMenu never changes; it always displays the last selected value, and never seems to get the value from the bean (e.g., it always display "No" even if the bean's value is "y").
    Any clues?

    Have you try
    binding="#{adoptRequestReviewHandler.currentAdoptionRequest.siteInspected}"

  • Report S_ALR_87012000 Asset Register does not show correct values sums

    Hi,
    I've taken a look at S_ALR_87012000 transaction - Asset Register (Italy) after an Assets Data transfer and something strange happens:
    1-  the sum of column Depreciation for year is not correct. It is a little bit strange because the single assets depreciation for year is correct. The same problem is in report S_ALR_87011990  - Asset history sheet
    2- if I put  an asset number range or the asset class in the report selection screen the report does not show some of the assets included in the range or in the asset class.
    Could you explain me why? Is there some program bug?
    Thanks in advance
    Giovanna

    Hi
    If you are executing the reports for previous / future years - execute them as of last day of the fiscal year
    The execution for current year can have any date of the fiscal year for report execution
    BR,Ajay M

Maybe you are looking for