所有这些选项卡都是在Windows窗体中动态创建的。我想在单击按钮时打开特定的选项卡页面。
例如,单击一个按钮(该按钮不是选项卡页按钮,而是其他执行按钮),我想显示选项卡3。
我能够获取选项卡页数,但无法打开特定的选项卡。
private void toolStripButton1_Click(object sender, EventArgs e)
{
int tabcount = Main_tab.TabCount;
MessageBox.Show(tabcount.ToString());
}