C# – Activate tabpage of TabControl

ctabcontroltabpagewinforms

I am using TabControl in #.NET application. By default first tab page of TabControl is showing in form loading. I want to activate/show other tab pages in form loading. Programmatically, how can I show other tab page?

Best Answer

tabControl1.SelectedTab = MyTab;

or

tabControl1.SelectedTab = tabControl1.TabPages["tabName"];

Where tabName is the Name of the tab you want to activate (tabName is NOT the text display).

Related Topic