private void LogMain_KeyDown(object sender, KeyEventArgs e) { if (e.Control && e.KeyCode == Keys.F) { FrmLogFind.Close(); FrmLogFind = new LogFind(this); FrmLogFind.Show(); } if (e.KeyCode == Keys.F3) { if (FrmLogFind.Visible) { FrmLogFind.Find(); } } if (e.KeyCode == Keys.F4) { if (FrmLogFind.Visible) { FrmLogFind.FindNext(); } } if (e.Control && e.KeyCode == Keys.S) { int iIdx = tabControl1.SelectedIndex; if (iIdx >= 0 && iIdx < m_iMaxArray) { lst[iIdx].SaveData(); } } //if (e.Control && e.KeyCode == Keys.C) //{ // int iIdx = tabControl1.SelectedIndex; // ListView.SelectedListViewItemCollection breakfast = lst[iIdx].Lsv.SelectedItems; // string sTemp = ""; // if (breakfast.Count > 1000) return; // foreach (ListViewItem item in breakfast) // { // for (int j = 0; j < item.SubItems.Count; j++) sTemp += item.SubItems[j].Text + ", "; // sTemp += "\r\n"; // Clipboard.SetText(sTemp); // } //} if (e.KeyCode == Keys.Escape) { //notifyIcon1.Visible = true; Hide(); } }
public LogMain() { InitializeComponent(); this.TopMost = true; m_iMaxListCnt = Eqp.m_iMaxListCnt; //Fre Init Timer = new CTimer(); // //notifyIcon ContextMenu contextMenu1 = new ContextMenu(); //contextMenu1.MenuItems.Add(new MenuItem("OPEN")); //contextMenu1.MenuItems.Add(new MenuItem("EXIT", new EventHandler((s, ex) => this.Close()))); contextMenu1.MenuItems.Add(new MenuItem("EXIT", new EventHandler(FormExit))); notifyIcon1.ContextMenu = contextMenu1; notifyIcon1.Visible = true; FrmLogOption = new LogOption(this); FrmLogVersion = new LogVersion(); FrmLogFind = new LogFind(this); //m_iMaxArray = OM.LogInfo.iTagCnt; fs = new FileStream[m_iMaxArray]; sw = new StreamWriter[m_iMaxArray]; //OnMakeNewLog(); _pIgnrList.Clear(); lst = new MsgList[m_iMaxArray]; for (int i = 0; i < m_iMaxArray; i++) { lst[i] = new MsgList(); lst[i].Ary.Clear(); } iDayCount = DateTime.Now.Day; tabControl1.TabPages.Clear(); TabPage tp = new TabPage("DEFAULT"); tabControl1.TabPages.Add(tp); lst[0].Lsv.Parent = tp; lst[0].Lsv.Dock = DockStyle.Fill; ListViewDispInit(OM.LogInfo.iTagCnt); }
private void fINDToolStripMenuItem_Click(object sender, EventArgs e) { FrmLogFind.Close(); FrmLogFind = new LogFind(this); FrmLogFind.Show(); }