private void btnEdit_Click(object sender, EventArgs e) { if (Convert.ToInt32(lblID.Text) <= 0) { return; } var model = new DealerModel() { DealerId = Convert.ToInt32(lblID.Text), DealerName = lblName.Text, DealerAddress = lblAddress.Text, PhoneNo = lblPhone.Text, MobileNo = lblMobile.Text, Email = lblEmail.Text, RegionId = _regionId, DelearIncharge = lblIncharge.Text }; var frm = new FrmDealerEntry(model, this); frm.ShowDialog(this); }
private void btnEdit_Click(object sender, EventArgs e) { if (Convert.ToInt32(lblID.Text) <= 0) return; var model = new DealerModel() { DealerId = Convert.ToInt32(lblID.Text), DealerName = lblName.Text, DealerAddress = lblAddress.Text, PhoneNo = lblPhone.Text, MobileNo = lblMobile.Text, Email = lblEmail.Text, RegionId = _regionId, DelearIncharge = lblIncharge.Text }; var frm = new FrmDealerEntry(model, this); frm.ShowDialog(this); }
private void btnNew_Click(object sender, EventArgs e) { var frm = new FrmDealerEntry(null, this); frm.ShowDialog(this); }