View Full Version : Referencing objects created in object config

3 Jun 2009, 4:04 AM
If an Ext object is created as a config option to another, how do you reference it. I guess an example will explain it better -

var grid = new Ext.grid.GridPanel({
ds: new Ext.data.Store({ ... whatever here ...})
bbar: new Ext.PagingToolbar({
store: ... <- this needs to be grid ds property

how do I reference the grid->ds property inside bbar? do I have to instantiate the datastore seperately to have a variable reference? i hope that makes sense...

3 Jun 2009, 4:11 AM
Just keep a reference to it when you create it.