private void radButtonElementCreate_Click(object sender, EventArgs e) { VisitaJayaPerkasa.Entities.CustomerTrans customerTrans = null; UserControl controllers = new CustomerTransEdit(customerTrans); Constant.VisitaJayaPerkasaApplication.mainForm.ShowUserControl(controllers); }
private void radButtonElementEdit_Click(object sender, EventArgs e) { if (showListCustomerTrans != null) { GridViewRowInfo gridInfo = CustomerTransGridView.SelectedRows.First(); string id = gridInfo.Cells[0].Value.ToString(); VisitaJayaPerkasa.Entities.CustomerTrans customerTrans = showListCustomerTrans.Where(c => c.CustomerTransID.ToString() == id).SingleOrDefault(); UserControl controllers = new CustomerTransEdit(customerTrans); Constant.VisitaJayaPerkasaApplication.mainForm.ShowUserControl(controllers); } }