Results 1 to 2 of 2

Thread: How to loadRecord when form has comboBox filled by DirectStore

  1. #1
    Sencha User
    Join Date
    Feb 2009
    Vote Rating

    Default How to loadRecord when form has comboBox filled by DirectStore

    I have a form with a comboBox that gets it's data via a DirectStore. The comboBox loads it's data fine, but the problem is it is loaded AFTER I call getForm.loadRecord(), so the value of my record is not selected in the combo.

    I know i can listen for the store's read event, but is there any good way to manage this? What if I have 2 comboBoxes etc?
    My code creates the form, which creates the combo, then loads the record into the form.
    Seems like this is a common problem, just looking for advise on the best way to deal with it.

  2. #2
    Sencha - Documentation Team slemmon's Avatar
    Join Date
    Mar 2009
    Boise, ID
    Vote Rating


    Listening to the stores' load events is what came to mind for me. Having the form load values as a response to the events seems the best way to ensure the data is loaded to the fields first since the data for the combos will come back asynchronously.
    Are you a Sencha products veteran who has wondered what it might be like to work at Sencha? If so, please reach out to our human resources manager:

Posting Permissions

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