private void button_OK_Click(object sender, EventArgs e) { this.button_OK.Enabled = false; if (this.listView_records.SelectedItems.Count == 0) { MessageBox.Show(this, "尚未选择事项"); this.button_OK.Enabled = true; return; } if (this.listView_records.SelectedItems.Count == 1) { string strPath = this.listView_records.SelectedItems[0].SubItems[0].Text; if (this.LoadNext != null && BiblioSearchForm.IsCmdLine(strPath)) { LoadNextBatchEventArgs e1 = new LoadNextBatchEventArgs { All = false }; this.LoadNext(this, e1); this.button_OK.Enabled = true; return; } } OnLoadDetail(); this.DialogResult = DialogResult.OK; this.Close(); }
void menu_loadRestAllBatch_Click(object sender, EventArgs e) { if (this.LoadNext != null) { LoadNextBatchEventArgs e1 = new LoadNextBatchEventArgs { All = true }; this.LoadNext(this, e1); } }