Can you hide/show a tab?
2006/06/08 12:56
Viewed 8619 times
Replies: 1/2

I have a rollbar with 3 tabs.
I want to hide/show tab 2 and 3 at runtime.
Is this possible?

guus

Re: Can you hide/show a tab?
2006/06/08 13:03
Viewed 11745 times
Replies: 1/1

Assuming you have kept a reference to the rollbar object:

var rb = DynarchRB.setup(...);

you can later access a few properties.  Not sure if the "tabs" property is documented, but anyway, it keeps an array with references to each tab element.  You should be able to hide a tab like this:

rb.tabs[1].style.display = "hidden";

and later make it visible with:

rb.tabs[1].style.display = "";

Note that the above will hide/show the second tab.  As in any JavaScript array, indexes are zero-based—to hide/show the first tab you'd use rb.tabs[0].

Hope this helps.

last
Re[2]: Can you hide/show a tab?
2006/06/09 14:35
Viewed 13786 times
Replies: 0/0

Works, thanks!

guus

last
Google