private void btnViewDataTable_Click(object sender, EventArgs e) { DataTable dt = new DataTable(); dt.Columns.Add("Catalogue"); dt.Columns.Add("Count Missing Descriptions"); dt.Columns.Add("Missing List"); foreach (IGrouping <Catalogue, ExtractionInformation> g in _activator.CoreChildProvider.AllExtractionInformations.GroupBy(ei => ei.CatalogueItem.Catalogue)) { if (!ShouldHaveDescription(g.Key)) { continue; } var missing = g.Where(ei => string.IsNullOrWhiteSpace(ei.CatalogueItem.Description)).ToArray(); dt.Rows.Add(g.Key.Name, missing.Count(), string.Join(",", missing.Select(m => m.CatalogueItem.Name))); } DataTableViewerUI dtv = new DataTableViewerUI(dt, "Catalogue Items Missing Descriptions"); var form = new SingleControlForm(dtv, true); form.Show(); }
private void ToggleAdvanced() { var db = serverDatabaseTableSelector1.GetDiscoveredDatabase(); if (db == null) { return; } //flip it var advanced = new CreateNewCatalogueByImportingFileUI_Advanced(Activator, db, _selectedFile, true, _projectSpecific); var form = new SingleControlForm(advanced); form.Show(); }
public static void TestHarness() { MersenneTwister mt = new MersenneTwister(); Series series = new Series("Random", ChartType.Point); for (int i = 0; i < 1000; ++i) { series.addPoint(mt.RandomDouble(), mt.RandomDouble()); } MultiChart2D chart = new MultiChart2D(); chart.addSeries(series); SingleControlForm form = new SingleControlForm(); form.setControl(chart); form.Show(); }