I have two windows forms in a C# application. One called frmMessages and the second frmAdmin.
On the frmMessage form I have a menu called moveToToolStripMenuItem, which I need to make invisible from frmAdmin.
That was achieved using the code below. However, another problem crept up. Every time frmMessage is re-loaded the menuStrip is
back to its original position. So, what I really need is to keep the strip invisible until switched to visible and, when switched to visible, stays visible until switched to invisible.
I created the following public method on frmMessages:
public void ShowHideMenu()
this.Visible = true;
ToolStripMenuItem item = new ToolStripMenuItem();
item = this.moveToToolStripMenuItem;
if (item.Visible == true)
item.Visible = false;
In frmAdmin I created a button that calls the above method:
private void button1_Click(object sender, EventArgs e)
frmMessage Frm = new frmMessage();
Please advise. Thank you.