OK, works but makes the code difficult to read if you see: MyTabStrib.SelectedIndex = 4; Also if there will be changes in the future (new tab or hiding/showing tabs dynamically) the resulting code will be difficult to maintain.
MyTabs.ShowTab("HistoryTab");
e.g. (pseudo-code from Refelctor)
public bool ShowTab(string tabID)
{
int tabCount = 0;
for (int i = 0; i < this.get_Items().Count; i++)
{
if (this.get_Items().get_Item(i).GetType() == typeof(Tab))
tabCount++;
if (this.get_Items().get_Item(i).get_ID() == tabID)
{
base.set_SelectedIndex(tabCount - 1);
return true;
}
}
return false;
}