public FrmVechileDetail() { reciever = new VehicleReciever(); helper = new DataHelper(); InitializeComponent(); Configuration(); RefreshList(); }
private void FrmSalesTransport_Load(object sender, EventArgs e) { vehicleReciever = new VehicleReciever(); transportReciever = new TransportationReciever(); helper = new Helpers.DataHelper(); // Fill transportation list helper.FillCombo(cmbTransport, GetTransports()); FillVehicleList(); if (_model != null) { cmbTransport.SelectedIndex = GetTransports().Select((obj, index) => new { obj, index }).Where(x => x.obj.Value == _model.TransportationID.ToString()).Select(x => x.index).FirstOrDefault(); if (_model.TVehicleNumberID > 0) { cmbVehicleNumber.SelectedIndex = GetVehicles().Select((obj, index) => new { obj, index }).Where(x => x.obj.Value == _model.TVehicleNumberID.ToString()).Select(x => x.index).FirstOrDefault(); } txtDriverName.Text = _model.TEmployeeName; txtDriverMobNumber.Text = _model.TEmployeeMobNumber; } }
public FrmAddEditVechile(VehicleModel model) { reciever = new VehicleReciever(); _model = model; InitializeComponent(); }
public FrmAddEditVechile() { reciever = new VehicleReciever(); InitializeComponent(); }