SelectOneChoice with static Value

I want to create a simple selectOnechoice . I create input form that include :
name : _________ => I use af:inputText
department : _________ => I use af:selectOneChoice, that is a static list following code:
<af:selectOneChoice value="#{bindings.PersonEntryDepartment.inputValue}" label="department" id="selectOneDepartment" unselectedLabel="select department">
<af:selectItem label="Computer Science" value="0" binding="#{addPerson.selectItem1}" id="selectItem1"/>
<af:selectItem label="Science" value="1" binding="#{addPerson.selectItem2}" id="selectItem2"/>
</af:selectOneChoice>
when I click ok , I get value
name = value that I entered
department = null
How to get value from af:selectOneChoice, I want to receive department's value is 0 or 1

Hi,
try setting valuePassThrough on the selectOneChoice to "true"
Frank

Similar Messages

  • Possible to simulate a spreadsheet for input, with static values per row

    Haven't seen this done but thought I'd ask, is it possible to simulate a spreadsheet interface in Apex? Basically, I have 9 columns each of which needs to be filled out for 10 time periods per day (row), and it's easiest for the user to tab across the columns then down to a new row / next timeslot, to fill out the whole day's worth of data, rather than entering hour by hour & then changing the timeslot manually. This would require that the value for column 1 of row 1 = 8, column 1 of row 2 = 9, column 1 of row 3 = 10 and so on. So, a tabular form but with static values on each row.
    Is this possible & if so, any pointers to what to start researching to make this work would be greatly appreciated. I know they can work in a spreadsheet & upoad it and we may go that way but this seemed like an interesting problem to see if Apex could handle it; I just am uncertain where to start on it is all.
    Many thanks for your pointers!
    gp
    Edited by: 834058 on Jul 18, 2011 10:37 AM

    Tabular report, with some modifications to have rows added at start of usage. User would on occasion need to click a control to add rows..
    Thank you,
    Tony Miller
    Webster, TX
    There are two kinds of pedestrians -- the quick and the dead.
    If this question is answered, please mark the thread as closed and assign points where earned..

  • OBIEE 10g - Logical column with static value

    I created a logical column with static numeric value in it and added it to presentation layer. The column is not showing up in Answers. All other columns I added are showing up. The issue is with this one only.
    I have verified permissions on this column in presentation layer. I tried reloading server metadata in answers, restarting all services but it didn't help.
    One thing I noticed this column is showing fx icon instead of Σ icon.

    Kid,
    The fx means it is a calculated column/formula and the sigma means that you've added some aggregation type to the column.
    Either way it shouldn't matter and your column should be showing up.
    I would attempt to create a new column and in the fx field try entering static text and see if that allows the column to be visible after dragging it to the presentation layer subject area.
    Also what is the value that you are adding?

  • Evaluate function doesn't work with Static values

    Hi All,
    I have been trying to call a evaluate function and have been successfully in calling it..but i face problem when i pass any static values to it...
    For eg
    when i try calling the function using one of the columns...it works fine
    Evaluate('dbo.Hello(%1)',"Dim table_name"."Department" )
    the function normally changes it to upper case.so i get all the value in the column in department in upper case.
    but when i call any static value like
    Evaluate('dbo.Hello(%1)','hello') it throws the following error..
    [nQSError: 43113] Message returned from OBIS. [nQSError: 43119] Query Failed: [nQSError: 42015] Cannot function ship the following expression: Evaluate( dbo.Hello(%1),'hello') . (HY000)
    Can any one please help me in this
    Regards
    SK

    Which version of Jdev are you using? What are the results you are getting?

  • SelectOneChoice with Distinct Values of Same ViewObject as Table

    JDev 11.1.1.6
    Scenario:
    One database table (MyTable) with 2 columns (MyDate and MyValue).
    MyDate     |  MyValue
    31-JUL-13  |    5.00
    31-JUL-13  |   10.00
    30-JUN-13  |   20.00
    30-JUN-13  |   13.00
    I need a page that has a selectOneChoice with a distinct list of MyDate and a table that displays only records associated with the selected date.
    So, the user should be able to select 30-JUN-13 from the selectOneChoice and the table should refresh with just the 2 records for that date.
    I am sure I am over-thinking this but do I need to create 2 entities?  If so, how can I create an entity for a distinct list from a table?
    Can I accomplish this with 2 view objects?
    Is there an easier way (like using an LOV on the Entity Attribute)?
    Any advise would be appreciated.
    Ray

    No, one EO will be enough. On this you build two VO one with the distinct query and one with the exact date query.
    Timo

  • PerformanceCounter.NextValue with static value of Performance Monitor

    Hi !
    I have one question about the documentation "PerformanceCounter.NextValue Method for .Net Framework 4.5".
    In the remark note we have the following:
    If the calculated value of a counter depends on two counter reads, the first read operation returns 0.0. Resetting the performance counter properties to specify a different counter is equivalent to creating a new performance counter, and the
    first read operation using the new properties returns 0.0. The recommended delay time between calls to the NextValue method is one second, to allow the counter to
    perform the next incremental read.
    But i need the counter "Current Bandwith" of "Network Interface" category, and it is static, its value does not change. I need to do two readings NextValue for static counters?
    Thanks!

    Hi Rafael,
    I think this thread is specific to Windows Performance forum. This form is to discuss problems about CLR development. So I am helping you to move this thread directly into that forum. Thank you for your understanding.
    Best Regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Adding Expired heading with static value for reverse proxy

    I'd like to add an Expired heading to a response leaving a reverse proxy to make sure that the browser will not cache the file locally (or at least attempt to prevent it).
    Is this possible with SWP? I cannot find out how to do this in the admin interface at least. I'm running 4.0.5 B04
    thanx,

    I'd like to add an Expired heading to a response leaving a reverse proxy to make sure that the browser will not cache the file locally (or at least attempt to prevent it).
    Is this possible with SWP? I cannot find out how to do this in the admin interface at least. I'm running 4.0.5 B04
    thanx,

  • Static values of message choice

    hi,
    I want to create a message choice with static values, without VO.
    how can i do this?
    thx

    I want to put in a list values of currency.
    I have create VO DeviseVO with two attribute :
    RowKey : primaryKey,number
    Values : Varchar
    i have tried this code but the numberd displayed is 0
    public void initializeMethod(){
    String values []={"Dinar","Euro","Dollar"};
    DeviseVOImpl pervo=getDeviseVO1();
    if(pervo.getFetchedRowCount()==0)
    for(int i=0;i<3 ;i++)
    pervo.executeQuery();
    Row prow = pervo.createRow();
    pervo.insertRow(prow);
    try
    prow.setAttribute("RowKey",new Number(i));
    prow.setAttribute("Values",values [ i ] );
    pervo.getCurrentRow().validate();
    catch(Exception ex)
    pervo.getCurrentRow().remove();
    pervo.executeQuery();
    System.out.println(pervo.getFetchedRowCount());
    }

  • How to get real value from selectOneChoice with javascript?

    Hi,
    How to get real value from selectOneChoice with javascript? The event.getNewValue() only gets me the index of the selected item, not the value/title.
    JSF page:
    <af:resource type="javascript">
    function parseAddress(event)
    alert("new value: " + event.getNewValue());
    </af:resource>
    <af:selectOneChoice label="Location:" value="" id="soc4">
    <af:clientListener type="valueChange" method="parseAddress" />
    <f:selectItems value="#{Person.locations}" id="si7"/>
    </af:selectOneChoice>
    HTML :
    <option title="225 Broadway, New York, NY-10007" selected="" value="0">225 Broadway (Central Office)</option>
    <option title="90 Mark St., New York, NY-10007" value="1">90 Mark St. (Central Office)</option>
    Thanks a lot.

    Something I was missing ,
    You need to add valuePassThru="true" in your <af:selectOneChoice component. I have personally tested it and got the actual value in alert box. I hope this time you got the real solution. You can also test the following code by your end.
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
    <jsp:directive.page contentType="text/html;charset=UTF-8"/>
    <f:view>
    <af:document id="d1">
    <af:form id="f1">
    <af:panelBox text="PanelBox1" id="pb1">
    <af:selectOneChoice label="Set Log Level" id="soc1"
    value="#{SelectManagedBean.loggerDefault}"
    valuePassThru="true">
    <af:selectItem label="select one" value="First" id="s6"/>
    <af:selectItem label="select two" value="Second" id="s56"/>
    <af:clientListener method="setLogLevel" type="valueChange"/>
    </af:selectOneChoice>
    <af:resource type="javascript">
    function setLogLevel(evt) {
    var selectOneChoice = evt.getSource();
    var logLevel = selectOneChoice.getSubmittedValue();
    // var logLevelObject = AdfLogger.NONE;
    alert("new value is : " + logLevel);
    //alert(evt.getSelection);
    //alert(logLevelObject);
    evt.cancel();
    </af:resource>
    </af:panelBox>
    </af:form>
    </af:document>
    </f:view>
    </jsp:root>

  • Query Issue with adding a static value

    I have written a query in SAP that works the way I need it to. I am going to schedule it so that SAP does a file transfer of the output to another area where the data will be accumulated.
    My problem is that I want the name of the system to appear at the end of each line but it is not in any table I can find to match up with the userid.
    EX:
    UserID        Group                          System
    JDOE         HR Query Group            P201
    The field for system is not in any tables but I want to add it and give it a constant/static value all the time in the output.
    Any ideas?
    Thanks!
    Justin Dauby -- SAP Security Analyst
    Kimball International Inc.,

    The name of the system is not in a table, but rather a structure called SYST. You can evaluate it using the system field sy-sysid.
    Another option is to call function module RFC_SYSTEM_INFO. The export parameter RFCSI_EXPORT will deliver the system id from component RFCSYSID of the structure RFCSI.
    Cheers,
    Julius

  • BO Webi: How to populate a variable with the set of static values for Graph

    Hi All,
    I have the data: Order number, Order Date, processing time coming from the SAP Bex query in the below format:
    Order No    Order Date    Processing time (Days)
    1                 Jan-2011      4
    2                 Jan-2011      5
    3                 Feb-2011      6
    In BO webi report, I have to report the number of orders which were processed in <1day, <2days, <3days,...<10days in a graphical view. i.e., X-Axis:  <1day, <2days, <3days,...<10days(10 static buckets for the processing days)
    Y-Axis: Number of Orders.
    The graphical output should be like below:
    X-Axis: <1day, <2days, <3days,<4days,<5days,<6days,<7days,<8days,<9days,<10days
    Y-Axis: 0, 0,0,0,1,2,3,3,3,3  (count(Order No)) (Cumulative count)
    I am able to calculate the number of orders individually for each of the 10 buckets. But the problem i am facing is that I am not able to hold the 10 static bucket values in a variable to use it for the x-axis in the Graph, as these 10 static bucket values are not coming from the backend source.
    I would like to know if there is way to populate a variable(to use it for the X-Axis in the graph) with the set of 10 static values.
    Any help would be highly appreciated.
    Thanks,
    Leela

    Hi ,
    I think we can use the variable as X-axis in chart.. but Variable Qulaification should be Dimension.
    can you try this?.
    Using efasion universe
    1) Select month and Sold at (unit price) , then run the query
    2) create the variable V_Month ==If [Month]=1 Then "Month1" Else "Month2"  (Note = Variable Qulaification should be Dimension)
    3) Create the variable V_Sum= sum (Sold at (unit price))
    4) create another variable V_Cumulative_Sum==[V_Sum]+Previous([V_Sum])
    Now add V_Month and V_Cumulative_Sum in table , then convert to chart.. now you can add the variable V_Month as X-axis of the chart.
    Hope this will help:)
    Thanks
    Ponnarasu K

  • Dropdown box with query *and* static values?

    Hi guys,
    If I had a dropdown box with a LOV being generated from a query,
    Select distinct PERSON from USER_TABLE
    Bill
    Fred
    Steve
    Is it possibe to somehow add static values so that they sit permanently on top of what ever values are produced by the query?
    Null
    Not Null
    Bill
    Fred
    Steve
    Thanks,
    Neil.

    select 'Null' d, 'Null' r from dual
    union all
    select 'Not Null' d, 'Not Null' r from dual
    union all
    select distinct person d, person r from user_table
    ...like that?
    Scott

  • 2 independent  selectOneChoice with the same value

    So I have two selectOneChoice with the same list values but different methodAction and methodIterator.
    when i change one's item and correspond to value, changing the other's item and value automatic, why?
    what is wrong? I'll send the code fragment
    How to make 2 independent list from the same business method?
    Jspx file
    <af:selectOneChoice value="#{bindings.*test1*.inputValue}"
    label="#{bindings.*test1*.label}">
    <f:selectItems value="#{bindings.*test1*.items}"/>
    </af:selectOneChoice>
    <af:selectOneChoice value="#{bindings.*test2*.inputValue}"
    label="#{bindings.*test2*.label}">
    <f:selectItems value="#{bindings.*test2*.items}"/>
    </af:selectOneChoice>
    the pagedefinition file is
    <executables>
    <methodIterator id="*queryTestIter*"
    Binds="*queryTest.result*"
    DataControl="SessionEJB1Local" RangeSize="-1"
    BeanClass="project1.DependentStrings"/>
    <methodIterator id="*queryTestIter1*"
    Binds="*queryTest1.result"*
    DataControl="SessionEJB1Local" RangeSize="-1"
    BeanClass="project1.DependentStrings"/>
    </executables>
    <bindings>
    <methodAction id="*queryTest*"
    InstanceName="SessionEJB1Local.dataProvider"
    DataControl="SessionEJB1Local"
    MethodName="*methodOne*"
    RequiresUpdateModel="true" Action="999"
    IsViewObjectMethod="false"
    ReturnName="SessionEJB1Local.methodResults.SessionEJB1Local_dataProvider_queryTest_result">
    </methodAction>
    <methodAction id="*queryTest1*"
    InstanceName="SessionEJB1Local.dataProvider"
    DataControl="SessionEJB1Local"
    MethodName="*methodOne*"
    RequiresUpdateModel="true" Action="999"
    IsViewObjectMethod="false"
    ReturnName="SessionEJB1Local.methodResults.SessionEJB1Local_dataProvider_queryTest1_result">
    </methodAction>
    <list id="*test1*" IterBinding="findallItemIter"
    StaticList="false" ListOperMode="0"
    ListIter="*queryTestIter*">
    <AttrNames>
    <Item Value="*item1Id*"/>
    </AttrNames>
    <ListAttrNames>
    <Item Value="id"/>
    </ListAttrNames>
    <ListDisplayAttrNames>
    <Item Value="stringValue"/>
    </ListDisplayAttrNames>
    </list>
    <list id="*test2*" IterBinding="findallItemIter"
    StaticList="false" ListOperMode="0"
    ListIter="*queryTestIter1*">
    <AttrNames>
    <Item Value="*item2Id*"/>
    </AttrNames>
    <ListAttrNames>
    <Item Value="id"/>
    </ListAttrNames>
    <ListDisplayAttrNames>
    <Item Value="stringValue"/>
    </ListDisplayAttrNames>
    </list>

    there is a list with different listIter's value,but it dos't work
    <list id="test1" IterBinding="findallItemIter"
    StaticList="false" ListOperMode="0"
    ListIter="queryTestIter">
    <AttrNames>
    <Item Value="item1Id"/>
    </AttrNames>
    <ListAttrNames>
    <Item Value="id"/>
    </ListAttrNames>
    <ListDisplayAttrNames>
    <Item Value="stringValue"/>
    </ListDisplayAttrNames>
    </list>
    <list id="test2" IterBinding="findallItemIter"
    StaticList="false" ListOperMode="0"
    ListIter="queryTestIter1">
    <AttrNames>
    <Item Value="item2Id"/>
    </AttrNames>
    <ListAttrNames>
    <Item Value="id"/>
    </ListAttrNames>
    <ListDisplayAttrNames>
    <Item Value="stringValue"/>
    </ListDisplayAttrNames>
    </list>
    Edited by: user638080 on Sep 9, 2008 12:22 AM

  • Problem with checkbox value and app.settings.getSetting()

    Hello everyone.
    I`ve got a problem with getting saved settings for checkbox.
    Saved settings doesn`t apply on checkbox value.
    It`s strange, but it always "true".
    So here piece of code:
    checkMe = 11;    //any value for the first time running
    if (app.settings.haveSetting("savea", "chck")) {                           
                          checkMe = app.settings.getSetting("savea", "chck");  // get saved value, else 11
                          alert("checkMe = "+checkMe)
                        if(checkMe == 11){
                            checkMe= false;   //if there is no saved settings, checkbox value will be false/ unchecked
                            alert("You run this script first time, so manual value will be 'false'")
                            }else{
                                checkMe = app.settings.getSetting("savea", "chck");     // if saved settings exist, get true or false
         alert("Yes, checkMe will = "+checkMe)       
    win.checkPanel.chkOne.value = checkMe;  /// checkbox value will equal saved checkMe
    var fff = win.checkPanel.chkOne.value;  // string for alert
    alert("aha! but checkbox value is  = " +fff+ "\n Why so?")     // here we`ve got always "true"
    win.checkPanel.chkOne.onClick  = function () {
        var path11 = win.checkPanel.chkOne.value;  //  checkbox value to variable
        app.settings.saveSetting("savea", "chck", path11);  //saving checkbox value
        alert("Saved this value - " + app.settings.getSetting("savea", "chck"))
    win.checkPanel.chkOne.value is always true.
    Can someone exmplain why and how to get rid of this static value?
    P.S. just in case, here is full code:
    function mainFun()
        this.windowRef = null;
    mainFun.prototype.run = function()
        /*----- UI -----*/
              var retval = true;
              var win = new Window("palette", "Check option", [150, 150, 460, 455]);
              this.windowRef = win;
              win.checkPanel = win.add("panel", [25, 150, 285, 265], "Checkbox");
              win.checkPanel.chkOne = win.checkPanel.add("checkbox", [10, 15, 125, 35], "Checkbox One");
              //win.checkPanel.chkTxtOne = win.checkPanel.add('edittext', [140, 15, 230, 35], '');
         win.quitBtn = win.add("button", [110,275,200,295], "Close");
    checkMe = 11;    //any value for the first time running
    if (app.settings.haveSetting("savea", "chck")) {                           
                          checkMe = app.settings.getSetting("savea", "chck");  // get saved value, else 11
                          alert("checkMe = "+checkMe)
                        if(checkMe == 11){
                            checkMe= false;   //if there is no saved settings, checkbox value will be false/ unchecked
                            alert("You run this script first time, so manual value will be 'false'")
                            }else{
                                checkMe = app.settings.getSetting("savea", "chck");     // if saved settings exist, get true or false
         alert("Yes, checkMe will = "+checkMe)       
    win.checkPanel.chkOne.value = checkMe;  /// checkbox value will equal saved checkMe
    var fff = win.checkPanel.chkOne.value;  // string for alert
    alert("aha! but checkbox value is  = " +fff+ "\n Why so?")     // here we`ve got always "true"
    win.checkPanel.chkOne.onClick  = function () {
        var path11 = win.checkPanel.chkOne.value;  //  checkbox value to variable
        app.settings.saveSetting("savea", "chck", path11);  //saving checkbox value
        alert("Saved this value - " + app.settings.getSetting("savea", "chck"))
              win.quitBtn.onClick = function() {
                  win.close();
        win.center();
              win.show();
              return retval;
    if(typeof(mainFun_unitTest) == "undefined") {
        new mainFun().run();

    Played around with different values, combinations...
    Doesn`t work too:
    checkMe = 111;    //any value for the first time running
    if (app.settings.haveSetting("333", "check")) {                           
                          checkMe = app.settings.getSetting("333", "check");
    alert(checkMe);
                    if(checkMe == 111){
                             win.checkPanel.chkOne.value= false;
                            }else{
                                if (checkMe != false){
                                win.checkPanel.chkOne.value= true;
                                }else{
                                win.checkPanel.chkOne.value= false;
    win.checkPanel.chkOne.onClick  = function () {
        var path11 = win.checkPanel.chkOne.value;
        var path12 = path11.toString();
        app.settings.saveSetting("333", "check", path12);
        alert("Saved value - " + app.settings.getSetting("333", "check"))

  • Adobe form -- Issue in Displaying Dynamic text along with Static text

    Hi All,
    I am having an issue when i am displaying a dynamic text along with static text in adobeforms.
    The dynamic text is slightly coming down and not aligned with the static text. i can see half row it is coming down.
    how to align both texts to be printed in same format.
    Request all of your expert advices in achieving this .
    Thank you in advance.
    Thanks&Regards,
    Phani Miriyaila.

    Hi,
    Select both dynamic and static text in the layout. Goto Object palette -> Layout. Give values to X,Y coordinates and Height & Width. Anchor properly and specify margins as well.
    Select both dynamic and static text in the layout. Right click on it and goto palettes -> Paragraph. It gives you the text alignment options. Align the text and give similar font and size.
    Thanks & Regards,
    Sanoosh

Maybe you are looking for

  • Summary : WF: PO - Emailing PO's from concurrent program using new workflow

    Hi Consultants, We have requirement to send PO - Emailing PO's from concurrent program using new workflow Request details> develop a way to email a PO as a PDF from the reports menu. Currently the PO can only be emailed from the PO approval screen. T

  • Can't get Java (JRE8U45) to work on IE11

    Hello, I must be missing something simple here but I have been unable to get any page requiring Java to load in Internet Explorer 11, at least on machines running Windows 7. I have tried it with multiple machines, all fully patched and up to date and

  • Passing XML String via HTTP Sender

    Hello everyone, currently we try to find a solution on the following requirement - maybe you have useful advice for us: 8 different business documents can be sent via a web-interface to SAP XI via the http sender adapter. We already have a customized

  • Import Manager problem

    Hi All I would like to ask to help me with very strange problem, I tried to google it but no success. When I use Importa Manager (ver 7,1 SP5) to import ~ 150 records there is a problem. I choose to upload all record to create, but only one is create

  • UWL Refesh Link

    Hi All, There is a UWL 'Refresh' available at the top right corner of the UWL iView. There are other options like 'Show filters' 'Manage substitution rules' etc... The 'Show filter / Hide filter' option is available as default link and the user has t