I want to set the value to the radiobutton dynamically.How it possible

Hi all,
I want to set the value to the radio button dynamically.but its giving undefined.
below is the code...
<table>
while(rSet.next())
String sim=rSet.getString(1);
System.out.println("the sim value is:"+sim);
%>
<tr class="forsmalllabel">
<td><input type="radio" name="acsRadio"
value="<%=rSet.getString(1).toString().trim() %>" onClick="validate(this.form)" > </td>
</tr>
<% } %>
</table>
sim variable giving the correct value ...but here ..
whenever I am clicking on the button..it giving undefied message.
my script is below..
<script language="javascript">
function validate(value)
alert("the value is:"+document.ASCCodeform.acsRadio.value);
return true;
</script>
any one help me on this..
urgent.
Thank you,
D.Nagireddy.

swish is correct, it can be an array of radio button or a single button. If you have created more than one radio button your will have to use
document.ASCCodeform.acsRadio[x].valuebut if it is only one you will make it:
document.ASCCodeform.acsRadio.value

Similar Messages

  • How to prevent numericstepper from setting the value to the defined Maximum when a number greater than maximum is entered in by keyboard and user hits the "Enter" key.

    I need to set the Maximum so that the use can use the mouse to change the value of numericstepper (and not go over a certain number), but at the same time I have to allow the user to enter their value by typing in the text field. When the user enters a number greater than the Maximum, I disable the "Ok" button of the dialog and show a red warning(error message). The issue is that the user can hit "Enter" and numeric stepper would set the value to the Maximum and the dialog box would close and the rest of code would run. I want the numericstepper not to change the value and keep showing the warning even if the user hits the "Enter".
    Note: Setting maxChar does not help since my maximum is 1000, and user might enter 5555
    I would appreciate the help.

    Thanks for trying to help, But
    The issue is that if I set the maximum value of stepper 1 greater than the max value that I want, then the user can select an invalid value(of myMax + 1) when he clicks on the UP arrow of the numeric stepper(which is not acceptable for what I am working on).
    I need to preserve the users invalid number, while not letting the user to select an invalid number by clicking UP key.
    I noticed that when the user enters a number greater than the Maximum, and then click on the down arrow, it would set the value to 1 less than the maximum. This is not acceptable either.

  • How to set the value in the xml node.

    Hi
    I am having the application PDF which can be submitted by user using the button. while submitting 
    i am using below code to set the value in the xml node.
       xfa.data.assignnode("employee.id","123",0):
    So its generating the xml like below.
    <employee>.
    <id>123</id>.
    </name>
    </employee>
    Now i need to generate the xml like  below.
    <employee id= "123" >
      </Name>
    </employee>
    So how to set/create the id node like above?
    Advance Thanks.
    Regards,
    Dhiyane

    Hi Dhiyane,
    You will have to set the contains property if the id node to "metaData", that is;
    xfa.data.assignNode("employee.id","123",0);
    xfa.data.employee.id.contains = "metaData";
    Very clumsy if you have a number of them, in which case you might want to look at using E4X.
    Good luck
    Bruce

  • How to set default values on the screen painter parameters?

    Hello ABAP Gurus,
    I would just want to ask how to set default values on the screen painter parameters.
    Thank you for your replies.

    Hi,
    To set default values for screen painter parameters initialize the field names with default values in the PBO module....
    say u have the field name as f_field1....
    in the PBO of that screen initialize it....
    f_field1 = '100'  "here 100 is the default value.
    <b>reward points if useful.</b>
    regards,
    Vinod Samuel.

  • Badi for setting default values in the transaction in APO.

    BADI NAME: SMOD_APOCF005 which is used for setting default values in the transaction.
    I have implemented the BADI using the below code but that BADI is not triggering. Please can you provide any solution for resolving this.
    As per my requirement I am trying to set default values for these three fields RRP_TYPE, WHATBOM, CONVH.
    DATA: LS_MATLOC LIKE LINE OF IT_MATLOC.
    LOOP AT IT_MATLOC INTO LS_MATLOC.
    LS_MATLOC-RRP_TYPE = '4'.
    LS_MATLOC-WHATBOM = '5'.
    LS_MATLOC-CONVH = '999'.
    MODIFY TABLE IT_MATLOC FROM LS_MATLOC TRANSPORTING RRP_TYPE WHATBOM CONVH.
    ENDLOOP.
    DATA: LS_MATLOCX LIKE LINE OF IT_MATLOCX.
    LOOP AT IT_MATLOCX INTO LS_MATLOCX.
    LS_MATLOCX-RRP_TYPE = 'X'.
    LS_MATLOCX-WHATBOM = 'X'.
    LS_MATLOCX-CONVH = 'X'.
    MODIFY TABLE IT_MATLOCX FROM LS_MATLOCX TRANSPORTING RRP_TYPE WHATBOM CONVH.
    ENDLOOP.

    The  BADI name: SMOD_APOCF005 .
    T.code at APO : /sapapo/mat1
    Once we enter in that T.Code with some Product and Location data.
    There under PP/DS tab.
    Under Planning Procedure there is a field PP Plng Procedure which I want to set as 4
    And under Order Creation there is Plan Explosion which needs to be set as 5
    And Under Horizons there is PP/DS Horizon which needs to be set as 999.
    BADi is implemented and active.
    And once the data is CIF from ECC to APO
    These default values are not set in the T code in APO and the BADi is not triggering.

  • How to set a value to the TextField on keyPress Event?

    Hai,
    I am using Jdev 11g.
    In my jspx page,i have an Input Text...I want to set a value to that input text when i press any button (say F2) inside that text field .I tried with clientListener and server Listener..But it is not set.
    In jspx page
    *========*
    <f:facet name="metaContainer">
    <trh:script>
    function onKeypressClientListner(evt) {
    var _txtField; var valueStr;
    _txtField = evt.getSource();        
    if (evt.getKeyCode() == AdfKeyStroke.F2_KEY) {
    valueStr = _txtField.getSubmittedValue()
    AdfCustomEvent.queue(_txtField,"onKeyPressServerListner",{payload:valueStr}, true); evt.cancel();
    </trh:script>
    </f:facet>
    <af:inputText label="Label 1" id="it1"
    binding="#{backing_CheckKeyPress.itxtInputText}">
    <af:clientListener method="onKeypressClientListner" type="keyUp"/>
    <af:serverListener type="onKeyPressServerListner"
    method="#{backing_CheckKeyPress.serverKeyListner}"/>
    </af:inputText>
    In CheckKeyPress.java
    *======*
    public void serverKeyListner(ClientEvent clientEvent)
    System.out.println("Inside Server Listener");
    itxtInputText.setValue("Hai");
    AdfFacesContext.getCurrentInstance().addPartialTarget(itxtInputText);
    After executing this,program will give output as Inside Server Listener . But the TextField value is not setting..

    I got it..Just set immediate property to true

  • I want to get the values from the second hiphen only

    Hey Guys,
    I have one column and the data like this
    col1 = 'AI463-901-001'
    Now,
    I want to get the values from the second hiphen only(any no. of values).
    Please can any one help me on this .
    Thanks in advance!
    Regards,
    -LK

    you have a mistake
    you result is -001
    this is right
      select substr('AI463-901-001',instr('AI463-901-001','-',1,2)+1) from dual;
      -- @user11928732 -  if you are using Oracle Database 11g, ttry this please
    with data as
      (select  'AI463-901-001'from dual)
      select substr(str,instr(str,'-',1,2)+1) from data;
      select substr(<YOUR COLUMN>,instr(<YOUR COLUMN>,'-',1,2)+1) from <YOUR TABLE>;result is : 001
    Edited by: Mahir M. Quluzade on May 3, 2011 5:37 PM

  • SelectManyListbox : How to set the value in the bean ?

    Hi,
    How can I set the selected values from a selectManyListbox in the bean ?
    My page:
                        <li>
                             <div class="box_multiple_selects clearfix">
                                  <div>
                                       <span>Esportes Selecionados</span>
                                       <h:selectManyListbox id="esportes_selecionados" size="10" value="artigoDetailsBean.esportes"/>
                                  </div>
                                  <div class="btns_fluxo fl">
                                       <button value="<<" name="all_right_hand">>></button>
                                       <button value=">" name="one_right_hand">></button>                                   
                                       <button value="<" name="one_left_hand"><</button>
                                       <button value="<<" name="all_left_hand"><<</button>
                                  </div>
                                  <div>
                                       <span>Esportes Cadastrados</span>
                                       <h:selectManyListbox id="esportes_cadastrados" size="10">
                                            <f:selectItems value="#{artigoDetailsBean.esporteList}" />
                                       </h:selectManyListbox>
                                  </div>
                             </div>
                        </li>
    "It´s a move right-left panel". In the right listbox are the database data, and the user click in the left arrow to move the elements (options) from right listbox to the left, and I´d like to get the selected values from the left listbox.
    The bean:
    public class ArtigoDetailsBean {
    private Collection<String> esportes;
         public Collection<String> getEsportes() {
              return esportes;
         public void setEsportes(Collection<String> esportes) {
              this.esportes = esportes;
         public List<SelectItem> getEsporteList() {
              List<SelectItem> esportes = new ArrayList<SelectItem>();
              for(Object esporte: artigoDetailsCommand.getEsporteList() ) {
                   esportes.add( new SelectItem( ((EsporteVO)esporte).getId().toString(), ((EsporteVO)esporte).getDescricao() ) );
              return esportes;
    Thanks in advance,
    Sergio Stateri Jr.
    [email protected]

    This blog shows an example of what you are trying to do - when the user clicks the left arrow it triggers an action event that puts the value into the left list, and vice-versa:
    [http://weblogs.java.net/blog/driscoll/archive/2008/11/jsf_20_the_swit_1.html|http://weblogs.java.net/blog/driscoll/archive/2008/11/jsf_20_the_swit_1.html]
    Ignore the 'JSF 2.0' in the header - it's not JSF 2.0 in this example!
    Also - don't post your email address on the forums - you might get spammed :)
    m

  • I have an Apple ID with a single  e mail address. I want to set multiple addresses in the same ID. Can I? If so how?

    I have an Apple ID with a single  e mail address. I want to set multiple addresses in the same ID. Can I? If so how?

    Howdy there johnzcarp,
    As I understand it you want to have more than 1 email address under your Apple ID. You can have what are called Alternate Email addresses associated with your Apple ID and this article will help you get those setup:
    Manage your Apple ID primary, rescue, alternate, and notification email addresses
    Alternate email address
    You can add one or more alternate email addresses for use with Apple services such as Game Center, FaceTime, Find My Friends, iMessage, and OS X notifications.
    Go to My Apple ID (appleid.apple.com).
    Select “Manage your Apple ID” and sign in.
    Add an alternate address:
    Select Add Email Address, then enter your alternate address. Apple will send a verification email to that address. Didn't receive the email?
    Follow the instructions in the email to verify the address.
    Edit an alternate address:
    Select Edit next to the address, then enter the new address. Apple will send a verification email to that address. Didn't receive the email?
    Follow the instructions in the email to verify the address.
    Delete an alternate address: Select Delete next to the address.
    Thank you for using Apple Support Communities.
    Take care,
    Sterling

  • Setting default value for a jcombobox based on the value not the index

    I am trying to set the default value for my combobox to the current year. One way I thought of doing it was to get the index of the value representing the current year and then use setSelectedInex to make it the default. Any ideas?
    The relevent section of code is below.
    GregorianCalendar gregorianCalendar = new GregorianCalendar();
    int year = gregorianCalendar.get(Calendar.YEAR);
    String currentyear = year + "";
    int startyears = 2000;
    int numyears = 25;
    JComboBox endyearcombobox = new JComboBox();
    endyearcombobox.setBorder( BorderFactory.createLineBorder(Color.DARK_GRAY));
    endyearcombobox.setFont(standardfont);
    endyearcombobox.addActionListener( new ActionListener() {
    public void actionPerformed( ActionEvent event ) {
    endyearcombobox = ( JComboBox )event.getSource();
    endyear = endyearcombobox.getSelectedItem();
    boolean same = endyear.equals(oldItem);
    oldItem = endyear;
    String[] endyearlist = new String[numyears];
    for(int i = startyears; i < startyears+numyears; i++){
    String item = new Integer(i).toString();
    endyearcombobox.addItem(item);
    Thanks
    Ged

    Thanks mate,
    That was what I was looking for. I still had a little more manipulation to do, but sent me on the right track and have got it working now. I don't know why I didn't think of it in the first place.
    Ged

  • How to set the value of the column as the value of other table coulmn.

    dear friends
    i have a table SO_D having coulm (so_no,item_cd,qty,rate,unit)
    and anather table so_tax(so_no,tax_code,tax_percent,tax_amt,item_cd,flag)
    now i have ALL VALUES in the first table i.e so_d
    but in table so_tax i have all values except item_cd.
    the values in the so_tax table comes from so_d by the formula ((qty*rate)*percent(which in so_tax table))/100) corresponding to each item_cd
    here so_no and item_cd are primary key in so_d and foreign key in the so_tax.
    and for each so_no the item_Cd is unique and my repeat for new so_no in the table so_d.
    now i have the problem that in the table so_tax the value in the coulmn item_cd is blank .
    but the tax amount is calculated for each item_cd .
    now i want to update the table with the item_Cd values ad they are in the so_d table according to the tax amount calculated by using above formula.
    please suggest the solution..
    any query please ask
    i can provide values for the each table..
    thanks in advance

    Data sample for the table so_d is
    SO_NO ITEM_CD QTY RATE UNIT
    AT0064 12000135 15 22163 NOS
    AT0064 12000136 15 20337.82 NOS
    AT0064 12000137 15 21902.27 NOS
    AT0064 12000138 15 20337.82 NOS
    AT0064 12000139 15 20337.82 NOS
    AT0149 CO000109 2 20755 NOS
    AT0149 CO000110 1 2502 NOS
    AT0149 CO000111 1 2502 NOS
    AT0149 CO000112 1 2502 NOS
    AT0149 CO000113 1 9328 NOS
    AT0149 CO000114 1 15476 NOS
    AT0149 CO000115 1 82150 NOS
    AT0149 CO000116 1 2915 NOS
    AT0149 CO000117 1 11766 NOS
    AT0149 CO000118 1 2968 NOS
    AT0149 CO000119 1 2968 NOS
    AT0149 CO000120 1 3286 NOS
    AT0149 CO000121 1 7950 NOS
    AT0149 CO000122 1 1908 NOS
    SAMPLE DATA FOR SO_TAX
    SO_NO TAX_CODE PERCENT AMT ITEM_cD FLAG
    AT0064 X02 4 13297 Y
    AT0064 X02 4 12203 Y
    AT0064 X02 4 13141 Y
    AT0064 X02 4 12203 Y
    AT0064 X02 4 12203 Y
    AT0149 V16 14.5 6018 Y
    AT0149 V16 14.5 363 Y
    AT0149 V16 14.5 363 Y
    AT0149 V16 14.5 363 Y
    AT0149 V16 14.5 1353 Y
    AT0149 V16 14.5 2244 Y
    AT0149 V16 14.5 11912 Y
    AT0149 V16 14.5 423 Y
    AT0149 V16 14.5 1706 Y
    AT0149 V16 14.5 430 Y
    AT0149 V16 14.5 430 Y
    AT0149 V16 14.5 476 Y
    AT0149 V16 14.5 1153 Y
    AT0149 V16 14.5 277 Y
    HERE ITE_CD IS BLANK

  • Need to set default values for the fields plant and location in ME21N

    Hi All,
    i need to set default values for the fields plant and location in ME21N tcode.
    In accout assignment if we give 'A' then we need to create asset by clicking the Asset tab,there you have the fields plant and location.
    How to resolve this?
    Thanks in Advance

    hi .
    i needed to set default strorage location and plant in personal setting  in me21n.
    i solve it with this way.
    go to program SAPLMEPERS in se38.
    create new function in output with the sample name :MODULE ZTEST_001 OUTPUT.
    in this module write:
    if MEPOITEM_PROP-WERKS is INITIAL and  MEPOITEM_PROP-LGORT is INITIAL.
    MEPOITEM_PROP-WERKS = '1000'.
    MEPOITEM_PROP-LGORT = '0032'.
    endif.
    this is the solution.
    best regards.
    maryam

  • HT4527 I recovered my macbook pro and i want to set my iphone to the new itunes which is on my laptop

    I recovered my macbook pro and i want to set my iphone to the new itunes which is on my laptop

    See Recover your iTunes library from your iPod or iOS device.
    tt2

  • I want to post the values of the form in the same Jsp Page

    I want to post the values of the form in the same Jsp page.

    Was that a question? Or are you just informing the world of your grand intentions?
    But yeah, all you need to do is direct your action to the same page you're in. So, if this is your foo.jsp, it'd be something like...
    <%
    if(request.getParameter("bar") != null) out.println("Hello");
    %>
    <form method="post" action="foo.jsp">
       <input type="text" name="bar" value="baz">
       <input type="submit">
    </form>When you submitted your form, it would post the value to the same JSP page as you're already in, and print out Hello to the screen. "Hello" would not print out on the first visit, as the request would obviously not contain the parameter "bar" yet.

  • I want to clear the values for the controls

    Hi all,
            After Adding Process, i want to clear the values for the controls in the form.
    Any one help me.

    If you use 2005, you can use the Formdata Event and catch the FORM_DATA_ADD event... In there you can clear the data

Maybe you are looking for

  • ERROR IN SAVING MARKETING PLAN

    HI forum when i saving the marketing plan in 5.0 getting the error like can't get RFC for SEM. anybody suggest how to solve this.

  • Need some help in java

    wat type of data structures should i use to implement a map with cities linking to each other. For Example there's cities A,B,C,D,E. City A is linked to Cities B,C,D,E. City B is linked to Cities A,C. City C is linked to Cities A. etc... and i need t

  • XI scenario configuration?

    We have a fairly complex XI configuration scenario that I would like to make a renamed copy of. For example, we have a configuration scenario called "TENANT001_SCENARIO" It contains a Business Service called "TENANT001" with 30+ communication channel

  • Trying to use adobe air 17 in a Flex Mobile ap

    hello, My Flashbuilder is using  AIR 17 as is visible in AIR aps. However, my Adobe flex mobile app won't let me update a certain line in the .xml I want to change: <?xml version="1.0" encoding="utf-8" standalone="no"?> <application xmlns="http://ns.

  • E-mailed photos received blurred

    MY photos on camera roll are lovely, but recently when I have emailed them to friends, they say that they are received blurred.   Also, previously when sending the photos, they filled the whole width of the email, but now they are reduced in size and