private void mnuToolsOneNote_Click(object sender, EventArgs e) { frmNote fNote = new frmNote(); fNote.Show(); this.Close(); }
private void cmnMainNote_Click(object sender, EventArgs e) { if (fNote == null) { fNote = new frmNote(); fNote.Disposed += new EventHandler(fNote_Disposed); } fNote.Show(); fNote.TopMost = true; if (!fNote.Visible) { fNote.Visible = true; } if (!Convert.ToBoolean(cConfig.GetParameter("Note.TopMost", "false"))) { Thread.Sleep(250); fNote.TopMost = false; } }
void fNote_Disposed(object sender, EventArgs e) { fNote = null; }