private void statusToolStripMenuItem_Click_1(object sender, EventArgs e) { string str = ""; InputForm dm = new InputForm(); dm.Owner = this; if (dm.ShowDialog() == System.Windows.Forms.DialogResult.OK) { str = dm.SearchText; } dm.Close(); dm.Dispose(); int n = 0; this.grid.BeginUpdate(); foreach (ListViewItem item in this.grid.Items) { if (item.Checked) { item.Checked = item.SubItems[4].Text.Contains(str); } if (item.Checked) n++; } this.grid.EndUpdate(); this.toolStripStatusSelect.Text = "Selected " + n.ToString(); }
private void addressToolStripMenuItem_Click(object sender, EventArgs e) { string str = ""; InputForm dm = new InputForm(); dm.Owner = this; if (dm.ShowDialog() == System.Windows.Forms.DialogResult.OK) { try { str = dm.SearchText.GetDomain(); } catch { } } dm.Close(); dm.Dispose(); if (str != "") this.selectRecipentAddress(str); }