private void lbtAddins_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { FrmSelectInstrument frm = new FrmSelectInstrument(_site.SiteInstruments); frm.ShowDialog(); if (frm.DialogResult == DialogResult.OK) { List <TestingArea> TaInSelectedIns = new List <TestingArea>(); foreach (Instrument i in frm.SelectedInstruments) { SiteInstrument si = new SiteInstrument(); si.Instrument = i; si.Quantity = 1; si.TestRunPercentage = 100; _site.SiteInstruments.Add(si); TaInSelectedIns.Add(i.TestingArea); } //AddTestingAreaInDemography(TaInSelectedIns); PopInstruments(); if (OnDataUsageEdit != null) { OnDataUsageEdit(this, new EventArgs()); } } }
private void lbtAddins_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { FrmSelectInstrument frm = new FrmSelectInstrument(_fCategoryInstrument, 1); frm.ShowDialog(); if (frm.DialogResult == DialogResult.OK) { List <TestingArea> TaInSelectedIns = new List <TestingArea>(); foreach (Instrument i in frm.SelectedInstruments) { ForecastCategoryInstrument si = new ForecastCategoryInstrument(); si.Instrument = i; si.TestRunPercentage = 100; si.ForecastId = _Fid; _fCategoryInstrument.Add(si); // DataRepository.SaveOrUpdateForecastCategoryInstrument(si); } PopInstruments(); //if (OnDataUsageEdit != null) //{ // OnDataUsageEdit(this, new EventArgs()); //} } }
private void lbtAddins_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { FrmSelectInstrument frm = new FrmSelectInstrument(_site.SiteInstruments); frm.ShowDialog(); if (frm.DialogResult == DialogResult.OK) { List<TestingArea> TaInSelectedIns = new List<TestingArea>(); foreach (Instrument i in frm.SelectedInstruments) { SiteInstrument si = new SiteInstrument(); si.Instrument = i; si.Quantity = 1; si.TestRunPercentage = 100; _site.SiteInstruments.Add(si); TaInSelectedIns.Add(i.TestingArea); } //AddTestingAreaInDemography(TaInSelectedIns); PopInstruments(); if (OnDataUsageEdit != null) { OnDataUsageEdit(this, new EventArgs()); } } }
private void lbtAddins_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { FrmSelectInstrument frm = new FrmSelectInstrument(_fCategoryInstrument,1); frm.ShowDialog(); if (frm.DialogResult == DialogResult.OK) { List<TestingArea> TaInSelectedIns = new List<TestingArea>(); foreach (Instrument i in frm.SelectedInstruments) { ForecastCategoryInstrument si = new ForecastCategoryInstrument(); si.Instrument = i; si.TestRunPercentage = 100; si.ForecastId = _Fid; _fCategoryInstrument.Add(si); // DataRepository.SaveOrUpdateForecastCategoryInstrument(si); } PopInstruments(); //if (OnDataUsageEdit != null) //{ // OnDataUsageEdit(this, new EventArgs()); //} } }