1. #1
    Sencha User
    Join Date
    Feb 2008
    Posts
    54
    Vote Rating
    0
    albert.sole is on a distinguished road

      0  

    Default combo box triggerAction

    combo box triggerAction


    Does anyone know which are the possible values of triggerAction in a ComboBox?

    the documentation just specify this:

    triggerAction : String
    The action to execute when the trigger field is activated. Use 'all' to run the query specified by the allQuery config option (defaults to 'query')


    but it does not specify for instance what you have to put if you don't want any triggerAction.

    Albert Sol

  2. #2
    Sencha - Community Support Team jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,361
    Vote Rating
    81
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default


    if i remember it's query or all

  3. #3
    Sencha - Community Support Team mystix's Avatar
    Join Date
    Mar 2007
    Location
    Singapore
    Posts
    6,236
    Vote Rating
    5
    mystix will become famous soon enough

      0  

    Default


    as @jgarcia@tdg-i.com said, it's either 'all' or 'query'.

    unless you implement your own custom override for the combo's private onTriggerClick() method:
    http://extjs.com/docs/?class=Ext.for...onTriggerClick

  4. #4
    Sencha User
    Join Date
    Feb 2008
    Posts
    54
    Vote Rating
    0
    albert.sole is on a distinguished road

      0  

    Wink


    Thanks,
    could you give a little more help?

    What I would like to do is to have a combo box which does not load anything automatically but uses a remote store. I just want to have values in the combo after calling store.load(), not before, even if the user clicks on the arrow.

    I tried to remove the triggerAction, and this is almost what I want, I mean if i remove the trigger the combo does not load the store at creation time but it does it when the user clicks on the arrow.

    Is there anyway to force the combobox to not load anything automatically?.

    Thanks.

  5. #5
    Sencha - Community Support Team mystix's Avatar
    Join Date
    Mar 2007
    Location
    Singapore
    Posts
    6,236
    Vote Rating
    5
    mystix will become famous soon enough

      0  

    Default


    just add an override for the current onTriggerClick() implementation, and do a specific check for triggerAction: 'query'.
    you'll see what i mean when you dive into the source.

    fyi, the combo's Store is only loaded when the dropdown list is first displayed.

Thread Participants: 2