private void dgBatchRun_CellContentClick(object sender, DataGridViewCellEventArgs e) { int batchRunId = int.Parse(dgBatchRun.SelectedCells[0].Value.ToString()); List <BatchRunHistogram> batchRunHistograms = BatchRunHistogramManager.GetBatchRunHistograms(batchRunId); dgHistogram.DataSource = batchRunHistograms; }
private void dgBatchRun_SelectionChanged(object sender, EventArgs e) { if (dgBatchRun.DataSource == null || dgBatchRun.SelectedRows == null || dgBatchRun.SelectedRows.Count == 0) { return; } int batchRunRow = dgBatchRun.SelectedRows[0].Index; int batchRunId = ((List <BatchRun>)(dgBatchRun.DataSource))[batchRunRow].BatchRunId; List <BatchRunHistogram> batchRunHistograms = BatchRunHistogramManager.GetBatchRunHistograms(batchRunId); dgHistogram.DataSource = batchRunHistograms; }
private void timerCheckTaskStatus_Tick(object sender, EventArgs e) { if (StatisticsManager.GetTotalNumberOfFinishedTasks() == int.Parse(this.tbPath.Text)) { BatchRunHistogramManager.GenerateHistogram(batchRun); List <BatchRunHistogram> batchRunHistograms = BatchRunHistogramManager.GetBatchRunHistograms(batchRun.BatchRunId); dgHistogram.DataSource = batchRunHistograms; tbEndTime.Text = DateTime.Now.ToString(); this.timerCheckTaskStatus.Stop(); MessageBox.Show("BatchRunId: " + batchRun.BatchRunId + " has finished."); } else { tbNumberOfFinishedTasks.Text = StatisticsManager.GetTotalNumberOfFinishedTasks().ToString(); } }
public List <BatchRunHistogram> GetBatchRunHistograms(int id) { return(BatchRunHistogramManager.GetBatchRunHistograms(id)); }