private void btnEdit_Click(object sender, EventArgs e) { if (Convert.ToInt32(lblID.Text) <= 0) { return; } var model = new ProductionMaterialModel() { ProductionMaterialId = Convert.ToInt32(lblID.Text), MaterialName = lblName.Text, UnitOfMeasurementId = _unitId, MaterialType = lblType.Text, Description = lblDesc.Text }; var frm = new FrmProductionMaterialEntry(model, this); frm.ShowDialog(this); }
private void btnEdit_Click(object sender, EventArgs e) { if (Convert.ToInt32(lblID.Text) <= 0) return; var model = new ProductionMaterialModel() { ProductionMaterialId = Convert.ToInt32(lblID.Text), MaterialName = lblName.Text, UnitOfMeasurementId = _unitId, MaterialType = lblType.Text, Description = lblDesc.Text }; var frm = new FrmProductionMaterialEntry(model, this); frm.ShowDialog(this); }
private void btnNew_Click(object sender, EventArgs e) { var frm = new FrmProductionMaterialEntry(null, this); frm.ShowDialog(this); }