TabPage没有Visible属性,所以只能通过设置将其与父控件(tabcontrol)的关联性去除就好了,如下面代码:

this.tclMain.Controls["tpgSize"].Parent = null;
this.tclMain.Controls["tpgColor"].Parent = null;

上述代码将原本是tabcontrol(tclMain)中的两个TabPag(tpgSize, tpgColor)e去掉了

this.tclMain.Controls.Add(tpgSize);

上述代码又将原本tabpage(tpgSize)添加回来

相关文章:

  • 2021-07-10
  • 2021-04-20
  • 2021-11-05
  • 2022-03-01
  • 2021-06-01
  • 2021-12-30
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-26
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-06
  • 2021-09-14
相关资源
相似解决方案