Tabber setActive()

The documentation for for tabbers’s setActive() is confusing.

This url … ctive.html says setTabActive is deprecated and to use setActive()

Then when you look at the tabbarcell api:

It shows setActive() as crosssed out as if not to use it. Then when you click on it, it says to use dhxComponent.cells(id).showView(name);

The setActive() function appears to be the correct function to use to programmatic change tabs.

Righr way is


Another old case can work only with dhtmlx_deprecated.js file

This is confusing because a view has not been created.

Here’s a tab group:

myTabbar = new dhtmlXTabBar("my_tabbar");
myTabbar.addTab("a1", "Tab 1-1", null, null, true);
myTabbar.addTab("a2", "Tab 1-2");
myTabbar.addTab("a3", "Tab 1-3");			

How would you switch to ‘a2’ using: dhxComponent.cells(id).showView(name)?

Try the next code sample:



The code above taking the first tab ‘a1’ and creating 3 views: the default, a grid and a tree. This does not address my questions.

I need to problematically switch to tab ‘a2’. How is this done?

For tab it WAS: myTabbar.setTabActive(id)
For tab is NOW: myTabbar.tabs(id).setActive();

For view it WAS: dhxComponent.cells(id).view(name).setActve();
For view is NOW: dhxComponent.cells(id).showView(name);

Don’t mix it