private void btnEdit_Click(object sender, EventArgs e) { if (Convert.ToInt32(lblID.Text) <= 0) return; var model = new UnitOfMeasurementModel() { UnitOfMeasurementId = Convert.ToInt32(lblID.Text), UnitName = lblName.Text, Description = lblRemarks.Text }; var frm = new FrmUnitEntry(model, this); frm.ShowDialog(this); }
private void btnNew_Click(object sender, EventArgs e) { var frm = new FrmUnitEntry(null, this); frm.ShowDialog(this); }