facebook

Question about the Combobox

💡
Our Forums Have Moved

For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub

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

    StevePimFox
    Member

    Hello.

    Been using the trial version of Mobione for about a week now, have to say it’s a great package and I’ll probably get the full package soon.

    I’m creating a few apps, but I’m unsure about the java bit, hopeless with java, I’ve nearly done my first app but having a problem with the java for something I want to do with the combobox, which is essential. I’ve set up multiple comboboxes, this is just an example, but I want a reset button so that when pressed, the fields in box one and box two both reset to the first field, in this case, when the reset button is pressed then both boxes shows ‘Item1’

    I’m guessing that the form box has to be checked. I have looked at the help pages you’ve done and included some of the code in the ‘onclick – run javascript’ box in the properties menu, i’ve even gone into the html source file and tried to put code into that, but no matter what I write and where I put it, nothng seems to work. I’m stuck. Could you please let me know what I’m doing wrong and where to put it and put me out of my misery.

    Thanks.

    #323911

    Albatros78
    Participant

    StevePimFox,

    here an exemple to help you. One button to display values and other one to eras value for each field.
    But, like you I have no good syntax to initialize the combobox to go back to the defautl selected item.

    how does it possible to go back to the firt “item1” by pressing button?

    Does anybody has the good syntax to do that? Wayne ?

    A good link to help you with widget is:
    http://genuitec.com/mobile/docs/javaScriptSnippets/javaScriptSnippets.html#combobox_widget_snippets

    Hope this helps

    Thanks

    Attachments:
    You must be logged in to view attached files.
    #323954

    Albatros78
    Participant

    Hi all,

    To help StevePimFox it would be very nice to have the good syntax to reset the combobox to the first item

    I tried different jquery syntaxes but no good result. It would be something like that:

    $(‘select#combobox1 option[selected”]’).removeAttr(“selected”);
    $(‘select#combobox1 option[first-child]’).attr(“selected”,”selected”);

    Who can give us the good syntax to reset the combobox to initila ?

    Thanks a lot for your help

    #324517

    support-michael
    Keymaster

    See the javascript snippets for interacting with combobox widgets here. Updated with combo snippets for setting selection.

Viewing 4 posts - 1 through 4 (of 4 total)
Reply To: Question about the Combobox

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