首页 > 代码库 > C# 隐藏TabControl标签

C# 隐藏TabControl标签

隐藏标签

?
1
2
3
tabControl.SizeMode = TabSizeMode.Fixed;
tabControl.Appearance = TabAppearance.FlatButtons;
tabControl.ItemSize = new Size(0, 1);

切换标签

?
1
2
3
4
5
foreach (TabPage tp in tabControl.TabPages)
{
    tabControl.TabPages.Remove(tp);
}
tabControl.TabPages.Add(tabPage1);