1

I need to create approximately 8 Comboboxes. I don't want to be static and it should be called dynamically using Ext-JS.

1 Answer 1

3

This piece of code creates a couple of comboboxes dynamically. I hope this is what you was looking for.

for (var i=0; i < 8; i++) {
    Ext.create('Ext.form.ComboBox', {
        fieldLabel: 'Combobox '+i,
        store: ['Option1','Option2'], //better to use a dynamic store
        renderTo: Ext.getBody()
    });
};
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.