Items in Carousel is of type Ext.util.MixedCollection, NOT an array although you can initialize it with an array.
Say,
c = new Ext.Carousel({
id: 'myCarousel'
items:[ {...}, {...} ]
});
to iterate:
var noOfItem = Ext.getCmp('myCarousel').items.length;
for(i=0;i<noofitem;i++){
Ext.getCmp('myCarousel').items.get(i);
}
沒有留言:
張貼留言