private void lvBorrow_MouseDoubleClick(object sender, MouseEventArgs e) { if (lvBorrow.SelectedItems.Count != 1) { MessageBox.Show("请选择一行!"); return; } try { if (lvBorrow.SelectedItems[0].ForeColor == Color.BlueViolet) { BeforeBorrow beforeBorrw = new BeforeBorrow(lvBorrow.SelectedItems[0].SubItems[0].Text, true, false); beforeBorrw.ShowDialog(); if (beforeBorrw.isTrue) { VipReturnWindow vipReturnWindow = new VipReturnWindow(beforeBorrw.vipId); if (vipReturnWindow.isDispose) { vipReturnWindow.Dispose(); } else { vipReturnWindow.ShowDialog(); } } } else { BeforeBorrow beforeBorrw = new BeforeBorrow(lvBorrow.SelectedItems[0].SubItems[0].Text, false, false); beforeBorrw.ShowDialog(); if (beforeBorrw.isTrue) { VipNoReturnWindow vipNoReturnWindow = new VipNoReturnWindow(beforeBorrw.vipId); if (vipNoReturnWindow.isDispose) { vipNoReturnWindow.Dispose(); } else { vipNoReturnWindow.ShowDialog(); } } } } catch (Exception ex) { } }
private void 非会员还车ToolStripMenuItem_Click(object sender, EventArgs e) { BeforeBorrow beforeBorrw = new BeforeBorrow(false, false); beforeBorrw.ShowDialog(); if (beforeBorrw.isTrue) { VipNoReturnWindow vipNoReturnWindow = new VipNoReturnWindow(beforeBorrw.vipId); if (vipNoReturnWindow.isDispose) { vipNoReturnWindow.Dispose(); } else { vipNoReturnWindow.ShowDialog(); } } }