The Modifiers
design-time property, controls member creation for the object you are modifying. It is not something you can change later. If you want to add tab pages to a tab control and you want to be able to change them later, define class members for them and assign appropriate access-modifier to them:
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private List<TabPage> tabPages;
private void referenceDesk_DoubleClick(object sender, EventArgs e)
{
tabPages = new List<TabPage>();
tabPages.Add(new TabPage("First"));
tabPages.Add(new TabPage("Second"));
foreach (var tab in tabPages)
tabControl1.TabPages.Add(tab);
}
....
}