private void LstTickets_MouseDoubleClick(object sender, MouseEventArgs e) { if (LstTickets.SelectedIndex >= 0) { Ticket t = (Ticket)LstTickets.SelectedItem; FrmTicket ticketDetails = new FrmTicket(t); ticketDetails.ShowDialog(); } }
private void LstTickets_MouseDoubleClick(object sender, MouseEventArgs e) { if (LstTickets.SelectedIndex >= 0) { Ticket t = (Ticket)LstTickets.SelectedItem; FrmTicket ticketDetails = new FrmTicket(t); ticketDetails.ShowDialog(); } //refreshes the form when the ticketDetails form is closed //displaying any changes made to the tickets inside that form //such as the updated ticket or deletion LoadTickets(); }
/// <summary> /// 选择影厅 进入座位选择 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void ltvShowChoose_Click(object sender, EventArgs e) { ListViewItem item = ltvShowChoose.SelectedItems[0]; if (Application.OpenForms["FrmTicket"] != null) { Form fm = Application.OpenForms["FrmTicket"]; //fm.Close(); fm.Activate(); if (((FrmTicket)fm).ShowplanId != item.Name) { ((FrmTicket)fm).ReSetParam(item.Name, dpdate, item.Tag.ToString()); } } else { FrmTicket form = new FrmTicket(item.Name, dpdate, item.Tag.ToString()); form.Text = "座位选择"; //form.MdiParent = Program._Main; form.WindowState = FormWindowState.Maximized; form.Show(); } }
private void btnScan_Click(object sender, EventArgs e) { FrmTicket ticket = new FrmTicket(); ticket.Show(); }