facebook

combobox problem

  1. MobiOne Archive
  2.  > 
  3. Getting Help – General
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #326406 Reply

    ramesh
    Member

    I have a problem.
    I use two comboboxes cb1 and cb2
    tb1 and tb2 are textfields to display the selection.
    whenever I wanted take the data from cb2 I always get the data from CB1

    Please help me to resolve this

    my code runs as follows
    function page61(){

    var hv_cable_size =$(‘select[#m1-page6-cb1] :selected’).val();
    var lv_cable_size =$(‘select[#m1-page6-cb2] :selected’).val();

    $(‘#m1-page6-tb2’).val(hv_cable_size);
    $(‘#m1-page6-tb1’).val(lv_cable_size);
    }

    #326422 Reply

    Kale
    Member

    Hi,

    var hv_cable_size =$(‘select[#m1-page6-cb1] :selected’).val();
    var lv_cable_size =$(‘select[#m1-page6-cb2] :selected’).val();

    $(‘#m1-page6-tb2‘).val(hv_cable_size);
    $(‘#m1-page6-tb1‘).val(lv_cable_size);

    I assume cb1 is for hv and tb1 should be the corresponding textfield.

    Your code will show lv (cb2) in tb1 and hv (cb1) in tb2.

    Try

    $(‘#m1-page6-tb1’).val(hv_cable_size);
    $(‘#m1-page6-tb2’).val(lv_cable_size);

    Hope it helps.

    Greetings Kale

    #326427 Reply

    ramesh
    Member

    I have tried it.But my problem is I always get the reading of first Combobox .
    The reading of second combobox is not at all displayed.
    It is not the display problem.I have to do further calculations based on the selected data.Selected data is not forthcoming from the second combobox.

    #326437 Reply

    Kale
    Member

    Maybe you should attach your complete custom.js file, so somebody can take a look into it.

    Greetings Kale

Viewing 4 posts - 1 through 4 (of 4 total)
Reply To: combobox problem

You must be logged in to post in the forum log in