Results 1 to 3 of 3

Thread: Dynamic Multiselect

  1. #1
    Sencha User DrunkenBeard's Avatar
    Join Date
    May 2011
    Posts
    55
    Answers
    2

    Default Answered: Dynamic Multiselect

    Hi there,

    I have a multiselect list working perfectly, I can select multiple records, no problem. Now I want to select 3 records of that list through code. I'm using the list.selModel.items.selected.push() method to add the records, I do a console.log() right before the list.refresh() to make sure list.selModel.items.selected has the 3 records and it does. Problem is, only the first record is selected on screen.

    Any ideas ?

    Thanks.

  2. You should use the select method on the list. YOu can pass in an array of records or indexes.

    http://docs.sencha.com/touch/1-1/#!/...-method-select

  3. #2
    Sencha Premium User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,379
    Answers
    3997

    Default

    You should use the select method on the list. YOu can pass in an array of records or indexes.

    http://docs.sencha.com/touch/1-1/#!/...-method-select
    Mitchell Simoens @LikelyMitch

    Check out my GitHub:
    https://github.com/mitchellsimoens

    Posts are my own, not any current, past or future employer's.

  4. #3
    Sencha User DrunkenBeard's Avatar
    Join Date
    May 2011
    Posts
    55
    Answers
    2

    Default

    Thanks a lot, worked like a charm

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •