private void BuildForm() { if (fupvc_quotation == null) { fupvc_quotation = new FUpvc_Quotation(); } fupvc_quotation.FUpvc_invoice_NeedToRefresh += VUpvc_invoice_NeedToRefresh; Parent.Controls.Add(fupvc_quotation); fupvc_quotation.Dock = DockStyle.Fill; fupvc_quotation.BringToFront(); fupvc_quotation.Show(); }
void Listgrid_RowAction(object sender, EventArgs e) { if (listgrid.SelectedRow == null) { return; } if (fupvc_quotation == null) { fupvc_quotation = new FUpvc_Quotation(); } BuildForm(); string pkValue = GetSelectedPkValue(); if (pkValue != null) { fupvc_quotation.SetAction(BtnEvent.Open, pkValue); } }