Need to know which grid is currently viewable in a tabbar

Hi,

I attached grids in each tab of a tabbar and I need to know, at every moment, which grid is currently viewable for the user …

Is it possible to get the attached grid when a tab is selected ? I did not find any API function to get the attached object inside a tab.

Thanks
Fred

Hi,

you may try to use the following to get grid object:

var grid = tabbar.cells(tabId).getView.grid;

The active tab can be got by getActiveTab() method.

Hi,
thanks Alexandra. I got it to run correctly with this modification :

var activeTab=tabbar.getActiveTab();
var activeGrid=tabbar.cells(activeTab).getView().grid;

Best regards, Frédéric.