Why is button value not changing?

I have a fairly complex form with several input text fields and buttons that have their values changed during operation.
The components are created from a session bean and are updated by two different mechanisms.
The input text fields are updated by user input.
The button acts as a toggle. When the user pushed the button, a javascript function checks the value of the button.
The button contains a single character, either a "X" or "O".
When the button is pushed, the javascript checks the value and changes it to the other.
Visually, this all works fine. Both the text fields and buttons behave as expected.
Here is the problem.
When the user pushes the "Apply" button, a session bean looks for the text fields and buttons using 'findComponent' for a specified ID.
They attempt to fetch the values of the components and update an internal array of values.
The input text component works fine.
User changes value, it is identified correctly, and the new value is detected on the component.
The commandButton component does not work as expected.
Visually, the component value changes properly.
When I use findComponent() and getValue(),. I get the original value.
I have verified that the component ID is correct - I print it with an Alert() method in the javascript and check it with the debugger before the findComponent() method.
But, what is returned from getValue() of the found component is the original value, not the value that is visually displayed on the form.
Can anyone explain why this happens and what I can do to get the correct visually displayed value from the button component?
Thanks.

<h:inputHidden value="#{myBean.myProp}" />Although this is annoying on the client side because the client id is rendered as the name.
Alternatively:
<input type="hidden" name="myProp" value="#{myBean.myProp}" />along with the following bean config:
    <managed-bean>
       <managed-bean-name>myBean</managed-bean-name>
       <managed-bean-class>MyBeanClass</managed-bean-class>
       <managed-bean-scope>request</managed-bean-scope>
       <managed-property>
            <property-name>myProp</property-name>
            <property-class>java.lang.String</property-class>
            <value>#{param.myProp}</value>
       </managed-property>
    </managed-bean>

Similar Messages

  • ICal failing to run applescripts: The 'Open' button does not change to 'Run', and the script file is opened but not executed on alert.

    iCal failing to run applescripts: The 'Open' button does not change to 'Run', and the script file is opened but not executed.

    Calendar (not called iCal anymore) does not include that capability any longer, apparently.  What you have to do now is go to Automator and create a Calendar Alert action.  You can add a Run AppleScript object to the action and paste in your script there, then when you save it, it will become available as a choice in the alert menu in Calendar.

  • Why submit button is not embedded in workspace?

    I'm developing a process in workbench in wich I create a PDF that have to be digitally signed in workspace. there are three sign fields for three different peoples. When first user open the PDF in workspace the submit button does't appear in the right bottom corner as usually.
    I'have to insert a submit button inside pdf form. Anyone can tell me the reason why?
    thank you in advance

    Workspace is designed to invoke a submit button on the pdf. The Workspace Complete button in the chrome will only be displayed if a submit button is found in the pdf. If no submit buttons can be found or if more than 1 submit button is found then the Workspace Complete button will not be visible. The latter case the user must click the button on the form.
    Given that a submit button can be configured to submit xdp data, pdf, xml data,... Workspace relies on the user designing the form how the data should be routed.
    Hope that's clear.

  • Making a button programmatically not change its 'physical' state when pressed

    I have this button:
    which changes into this when pressed:
    How do i programmatically make the button not change into its 2nd state when pressed? do i use property nodes? if so, how?
    thanks

    If you use the Colors Property Node, you can change the colors dynamically, so you can set it all green when you need it, then change it back to green and red.
    The only way you can intercept the button press is to use the Mouse Down? event in the event structure.  You will need to verify a left mouse click and then Discard the event.  That will be your inidcation the button has been pressed.  However, you will still need to track your state to not discard the event in the situations where you want the button to actuate.
    It is much easier to dynamically change the colors.

  • Simple Button.Text not changing properly

    Hi all,
    The WPF learning curve is steep.
    I have pulled my hair over this simple Button.Text change and I can't get it to work.
    In WinForms this works:
    Public Class Form1
    Private Sub BTN_1_Click(sender As Object, e As EventArgs) Handles BTN_1.Click
    BTN_1.Text = "CLICKED BUTTON 1"
    BTN_2.Text = "CHANGED BY BUTTON 1"
    End Sub
    Private Sub BTN_2_Click(sender As Object, e As EventArgs) Handles BTN_2.Click
    BTN_2.Text = "CLICKED BUTTON 2"
    BTN_1.Text = "CHANGED BY BUTTON 2"
    End Sub
    End Class
    I want to do the same thing in WPF
    <Window x:Class="MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="MainWindow" Height="350" Width="525">
    <Grid>
    <Grid.RowDefinitions>
    <RowDefinition/>
    <RowDefinition/>
    </Grid.RowDefinitions>
    <Grid.ColumnDefinitions>
    <ColumnDefinition/>
    <ColumnDefinition/>
    </Grid.ColumnDefinitions>
    <Grid Grid.Column="0" Grid.Row="0">
    <Button Name="BTN_1" Click="CLICK_BTN_1">
    <StackPanel>
    <TextBlock Name="CLICK_BTN_1_LABEL_1" Text="Button 1 text" VerticalAlignment="Top" Foreground="#BF000000" >
    </TextBlock>
    <TextBlock Name="CLICK_BTN_1_LABEL_2" VerticalAlignment="Top" Foreground="#BF000000">
    <Run FontSize="25">Button 1</Run>
    <Run FontSize="12">Label 2</Run>
    </TextBlock>
    </StackPanel>
    </Button>
    </Grid>
    <Grid Grid.Column="1" Grid.Row="0">
    <Button Name="BTN_2" Click="CLICK_BTN_1">
    <StackPanel>
    <TextBlock Name="CLICK_BTN_2_LABEL_1" Text="Button 2 text" VerticalAlignment="Top" Foreground="#BF000000">
    </TextBlock>
    <TextBlock Name="CLICK_BTN_2_LABEL_2" VerticalAlignment="Top" Foreground="#BF000000">
    <Run FontSize="25">Button 2</Run>
    <Run FontSize="12">Label 2</Run>
    </TextBlock>
    </StackPanel>
    </Button>
    </Grid>
    </Grid>
    </Window>
    Class MainWindow
    Private Sub CLICK_BTN_1(sender As System.Object, e As System.Windows.RoutedEventArgs) Handles BTN_1.Click
    ' CHANGE LABEL 1 ON BUTTON 1
    CLICK_BTN_1_LABEL_1.Text = "CLICKED BUTTON 1"
    ' CHANGE LABEL 1 ON BUTTON 2
    CLICK_BTN_2_LABEL_1.Text = "CHANGED BY BUTTON 1"
    End Sub
    Private Sub CLICK_BTN_2(sender As System.Object, e As System.Windows.RoutedEventArgs) Handles BTN_2.Click
    ' CHANGE LABEL 1 ON BUTTON 1
    CLICK_BTN_1_LABEL_1.Text = "CHANGED BY BUTTON 2"
    ' CHANGE LABEL 1 ON BUTTON 2
    CLICK_BTN_2_LABEL_1.Text = "CLICKED BUTTON 2"
    End Sub
    End Class
    This used to be so simple with WinForms, what am I doing wrong here?
    New to WPF

    Yeah, I saw that as well but now I am stuck again:
    Same project but I have put the buttons in a usercontrol
    <Window x:Class="MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:Component_Changes"
    Title="MainWindow" Height="350" Width="525">
    <Grid>
    <Grid.RowDefinitions>
    <RowDefinition/>
    <RowDefinition/>
    </Grid.RowDefinitions>
    <Grid.ColumnDefinitions>
    <ColumnDefinition/>
    <ColumnDefinition/>
    </Grid.ColumnDefinitions>
    <Grid Grid.Column="0" Grid.Row="0">
    <Viewbox Stretch="Fill">
    <ContentControl Name="UC_BTN1">
    <ContentControl.Content>
    <local:btn1 Margin="20"/>
    </ContentControl.Content>
    </ContentControl>
    </Viewbox>
    </Grid>
    <Grid Grid.Column="1" Grid.Row="0">
    <Viewbox Stretch="Fill">
    <ContentControl Name="UC_BTN2">
    <ContentControl.Content>
    <local:btn2 Margin="20"/>
    </ContentControl.Content>
    </ContentControl>
    </Viewbox>
    </Grid>
    </Grid>
    </Window>
    btn1.xaml
    <UserControl x:Class="btn1"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="300">
    <Grid>
    <Button Name="BTN_1" Click="CLICK_BTN_1">
    <StackPanel>
    <TextBlock Name="CLICK_BTN_1_LABEL_1" Text="Button 1 text" VerticalAlignment="Top" Foreground="#BF000000" >
    </TextBlock>
    <TextBlock Name="CLICK_BTN_1_LABEL_2" VerticalAlignment="Top" Foreground="#BF000000">
    <Run FontSize="25">Button 1</Run>
    <Run FontSize="12">Label 2</Run>
    </TextBlock>
    </StackPanel>
    </Button>
    </Grid>
    </UserControl>
    btn1.xaml.vb
    Public Class btn1
    Dim CL_BTN2 As btn2
    Private Sub CLICK_BTN_1(sender As Object, e As RoutedEventArgs) Handles BTN_1.Click
    ' CHANGE LABEL 1 ON BUTTON 1
    CLICK_BTN_1_LABEL_1.Text = "CLICKED BUTTON 1"
    ' CHANGE LABEL 1 ON BUTTON 2
    CL_BTN2.CLICK_BTN_2_LABEL_1.Text = "CHANGED BY BUTTON 1"
    End Sub
    End Class
    btn2.xaml
    <UserControl x:Class="btn2"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="300">
    <Grid>
    <Button Name="BTN_2" Click="CLICK_BTN_2">
    <StackPanel>
    <TextBlock Name="CLICK_BTN_2_LABEL_1" Text="Button 2 text" VerticalAlignment="Top" Foreground="#BF000000">
    </TextBlock>
    <TextBlock Name="CLICK_BTN_2_LABEL_2" VerticalAlignment="Top" Foreground="#BF000000">
    <Run FontSize="25">Button 2</Run>
    <Run FontSize="12">Label 2</Run>
    </TextBlock>
    </StackPanel>
    </Button>
    </Grid>
    </UserControl>
    btn2.xaml.vb
    Public Class btn2
    Dim CL_BTN1 As btn1
    Private Sub CLICK_BTN_2(sender As Object, e As RoutedEventArgs) Handles BTN_2.Click
    ' CHANGE LABEL 1 ON BUTTON 1
    CL_BTN1.CLICK_BTN_1_LABEL_1.Text = "CHANGED BY BUTTON 2"
    ' CHANGE LABEL 1 ON BUTTON 2
    CLICK_BTN_2_LABEL_1.Text = "CLICKED BUTTON 2"
    End Sub
    End Class
    No warnings in the code but the error is: 'Object reference not set to an instance of an object' and I thought I did, obviously not in the right way.
    New to WPF

  • Values not changed in Report

    Hi,
    in BEx 7.0 Query out put is confusing.
    when I loaded Data in the Cube 2nd time.
    double Values are displayed in the Query  .
    When I loaded the Data, I deleted Data in PSA and cube too.
    <b>For Example : Plan activity Quantity 1st time value is 100 then</b>
    2nd time when i delted the PSA data & Cube data, then I loaded Cube
    <b>the value of Plan activity Quantity 2nd time value is 200 then</b>
    3rd time when I delted the PSA data & cube data then once again I loaded Cube
    <b>the value of Plan activity Quantiy 3rd time value is 300.</b>
    when I deleted the PSA data & Cube Data, I checked in the Query no data it is showing.
    That clearly Indicates not the problem of Cube.
    Problem with the Query.
    I am wondering how it is displayed like this.
    may be some property i need to concentrate.
    Then I saveAs this Query then The New Query is showing the Right Result
    But old is showing Wrong values like (double,triple)
    can anybody encounted this type of Problem in BEx 7.0
    I have 30 Queries , I don't won't to SaveAs All these Queries,
    some Queries has in WorkBook.
    that's why I am checking the Properties.
    Please Help me to find the solution
    I will assign Points.
    Thanks
    prasanna

    Hi,
    the exact explication why you have to do this, I don't know...
    but, out of my experience, I've noticed that If your cube is right and your query is right, but you get wrong results, you have to regenerate the definition of the query. Not by saving the query, but by 'generate' in RSRT. And 9 out of 10, you get the right result :o)
    I think that SAP remembers a version of the querydefinition, and uses that definition. If you do generate, you give SAP a new version...
    Greatz
    Joke

  • Base Value not changing in MIGO Excise Tab

    Dear Gururs,
    We are using MIGO to capture & Post Excise Invoice for our Import PO (PO type ZIMP). the problem is, when we change the qty in MIGO Qty tab, corresponding base value is not getting update in Excise tab. Please suggest a solution.

    Hi,
    If you are doing a MIGO for Import consignment, duties are flow from Invoice booked thru MIRO, so doutful if you can change corresponding base value in MIGO.
    Regards,
    Vikas

  • Why my iMac does not change picture when waking from sleep ?

    My iMac has Yosemite installed, I have tried to kill the system preferences in the library but it did not solve the problem.
    I restarted, PRAM, repaired system permissions, log on off, etc. and nothing, nada !
    It used to work without problems, changing the picture on my desktop every time the computer was waken up.
    What it could be wrong ?
    I have noticed that the CPU is now above 55% most of the time and iStat says that SGProtocol Service is constantly in 99%. I don´t have a clue what that means.
    Any help would be appreciated.
    Thanks in advance,
    Rod

    OK. I found the solution.
    The computer changes the picture after sleep is activated from the power button but no from a hot corner, like it used to do. Obviously is a bug.
    I ruled out the iStat, SG Protocol and high CPU, which are not related with the problem.
    It is not a big deal, now I set it to change the image every hour, and it works !
    Thanks anyway.

  • Why the SCN do not change?

    I have three databases running for the test of stream replication. Today I alter the data of the N0.1 database. Applied_scn is the identify of data exchange between oracle databases. But I find that it's applied_scn keep the same as before I alter the data . At the same time, I find the data altered in NO.1 database has tranfer to remote database and applies. This happen but why applied_scn keep the same ? Has a delay ?
    who can tell me ?
    And I have another question. If I have no operation on a database running oracle 10.2.0.1,the applied_Scn and captured_scn keep increasing and the same value.
    Anyone has answer?

    APPLIED_SCN NUMBER is Newest SCN at which all changes have been applied. The values in the APPLIED_SCN and NEWEST_SCN columns will match if all available redo log data has been processed.

  • Why some items can not change issue method in Production Order?

    Hi,
    I have a Production Order which had been released.
    As some reason, I need to change issue method on some items in this Production Order, but I found that some items can be changed with a dropdown list, and some items can not be changed without dropdown list.
    Why they are different?
    What should I do to meet my users' request?
    Thanks.

    Hai wilson,
    sorry i visits forum after long time .. item category means , when create item group there are two option Service / Material if u select service , inventory come under that group only in "Back flush" other wise u can select "Manual / Back flush"
    Regards
    Janeesh

  • Why are my values not "taking"?

    I've had this problem intermittently, and now it's back and I
    don't know why.
    I have 2 datagrids with drag and drop. The source is an
    XMLList, as in:
    <items>
    <item ln1="Feta" ln2="crumbled feta" sn="feta" minQy="0"
    maxQy=".5" qty=".5" units="cup" />
    <item ln1="Fontina" ln2="shredded Fontina" sn="fontina"
    minQy="0" maxQy=".5" qty=".5" units="cup" />
    ... etc ...
    </items>
    For the destination, I have created an ArrayCollection to
    receive the dropped items. One column is a numeric stepper:
    <mx:DataGridColumn dataField="@qty" headerText="Quantity"
    width="70" itemEditor="myComponents.NSEditor"
    itemRenderer="myComponents.NSEditor"
    editorDataField="newTotal"/>
    Which uses this component:
    <mx:Script>
    <![CDATA[
    public function get newTotal ():Number{
    return step.value;
    ]]>
    </mx:Script>
    <mx:NumericStepper id="step" minimum="{XML(data).@minQy}"
    maximum="{XML(data).@maxQy}" stepSize=".25"
    value="{XML(data).@qty}" width="50"/>
    </mx:VBox>
    I check the totals in the list with:
    // adds up the quantities, returns sum
    public function getTotal(_arr:ArrayCollection) : Number {
    var _sum : Number = 0;
    var _length : Number = _arr.length;
    for(var i:Number=0; i<_length; i++) {
    var _item : Object = _arr.getItemAt( i );
    var _value : Number = _item["@qty"];
    _sum += _value;
    return _sum;
    The problem is, I drag a couple of items over, their default
    qty is 0.5 as indicated in the XML. But even if I change the
    steppers to 0.25, I'm still getting a total as if they're 0.5. Why
    is this?

    Make the getter newTotal bindable:
    [Bindable}
    public function get newTotal():Number{ ... }
    You may get either an error or warning telling you that you
    have to have a setter for newTotal as well. If you do, just add the
    setter, even though it won't do anything.
    Another approach would be to have a public variable in your
    NS component:
    [Bindable]
    public var changedQuantity:Number
    <mx:NumericStepper id="step" minimum="{XML(data).@minQy}"
    maximum="{XML(data).@maxQy}" stepSize=".25"
    value="{XML(data).@qty}" width="50"
    change="changedQuantity=step.value" />
    and then
    <mx:DataGridColumn dataField="@qty" headerText="Quantity"
    width="70" itemEditor="myComponents.NSEditor"
    itemRenderer="myComponents.NSEditor"
    editorDataField="changedQuantity"/>
    TS

  • Why column width will not change

    What keeps the width of a column from being updated or
    altered?
    I have a table that I want to adjust the width. I click the
    column to have it's properties visible and enter a new width in the
    properties panel, but the table remains with it's original width.
    Also, I get Width shown as a percentage and not a pixel
    measurement. Tried changing width attribute property from
    percentage to pixels. Did not work. I right clisked the column to
    "clear width" values. that did not work either.
    Also, drag and drop in design mode and moving the column
    width also has no effect. Is this a version bug?
    Thanks
    Jerry H

    Hi, see if this helps...
    Products Affected
    Mac OS X 10.5, Product Security, Safari 5.1 (Mac OS X 10.6), Safari 5.1 (OS X Lion)
    Safari 5.1.7 for OS X Lion, Safari 5.1.7 for OS X Snow Leopard, and Leopard Security Update 2012-003 disable out-of-date versions of Adobe Flash Player.
    Out-of-date versions of Adobe Flash Player do not include the latest security updates and will be disabled to help keep your Mac secure. If Safari 5.1.7 or Leopard Security Update 2012-003 detects an out-of-date version of Flash Player on your system, you will see a dialog informing you that Flash Player has been disabled. The dialog provides the option to go directly to Adobe's website, where you can download and install an updated version of Flash Player.
    Additional Information
    If you need to re-enable an out-of-date version of Flash Player, you can do the following:
        1.    Navigate to the /Library/Internet Plug-Ins (Disabled) folder.
        2.    Drag "Flash Player.plugin" into /Library/Internet Plug-Ins.
        3.    If the browser is running, quit and restart it.
    http://support.apple.com/kb/HT5271
    On the freeze, never been to FaceBook, but...
    Open Console in Applications>Utilities & see if there are any clues or repeating messages when this happens.

  • Drop down menu button will not change color

    I have built a 6 button  rollover dropdown menu bar in Flash CS4
    On five of the dropdown menus I can get the buttons to change color
    On the fifth dropdown I can see the button, but when rolled over I can't get the color to change.
    I have moved the buttons on the fifth drop down to the first drop down button and they work perfectly.
    Is this a bug in Flash CS4 or......
    thank you
    Sb!

    I appreciate your reply but those arrows were not the ones I was trying to describe. In the same box where you would type your web address on the far right is a small star and then next to it an arrow pointing down. If you click on this arrow, it normally drops down a list of the websites you commonly use. Or, if you are on a website ordering something, there might be a similar arrow that you need to select in order to choose which shipping you might want such as ground, next day air, etc., these are the kinds of arrows that are not working correctly now. Any ideas on these? Thanks for trying to help me.

  • Why does the curser not change from an arrow to a hand and allow me to click of words that are "clickable"?.

    In any website and on any webpage I can not click of links/words in the top 3cm of the page. Everything below I can click on with no problems. Why is this happening? How do I fix it? I am not computer literate so any help you can give me please respond in clear and detailed steps. I have tried reloading Mozilla Firefox but I am not sure it did re-load this internet browser. I have emptied my cookies, history and cache. What is the problem? Why is it doing it and how do I fix it? Please help me and urgently. Thanks.

    the-edmeister, you are a genious. I went to "view" then "toolbars" and de-selected "yahoo toolbar" and then moved the curser over my firefox page and it now works completely including the problem area (the top 3 cm of each screen). Thank you, thank you, thank you, thank you, thank you, thank you. You have no idea how good I feel know on this otherwise cold, windy and rainy day.

  • The app may shut down on its own or the button will not change it

    I'm having a problem with an a search unexpectedly closing; then at times I'm unable to get the application to close and have to press the button a number of times to get anything to happen.  I only have one application open while this is happening.  Also, when this is happening, the pad seems extremely slow.  Could someone help diagnose what is going on with my IPad?

    Try here:
    iOS: Not responding or does not turn on

Maybe you are looking for