Beispiel #1
0
        private void Context_RunningComplete(object sender, EventArgs e)
        {
            var simcData = (SimcRunnerData)sender;
            var window   = new ResultsWindow();

            window.Top  = App.Current.MainWindow.Top;
            window.Left = App.Current.MainWindow.Left;
            ((ResultsData)window.DataContext).LoadResultPath("results" + System.IO.Path.DirectorySeparatorChar + simcData.guid);

            var htmls = Directory.EnumerateFiles("results" + System.IO.Path.DirectorySeparatorChar + simcData.guid, "*.html");

            ((ResultsData)window.DataContext).MergeResults(simcData.model, simcData.guid, htmls);
            App.Current.MainWindow = window;
            this.Close();
            window.Show();
        }
Beispiel #2
0
        private void Button_Click_1(object sender, RoutedEventArgs e)
        {
            var window        = new ResultsWindow();
            var context       = (ResultLoaderData)this.DataContext;
            var windowContext = (ResultsData)window.DataContext;

            if (!windowContext.LoadResults(context.SelectedTag.Label))
            {
                this.Close();
                return;
            }
            window.Top             = App.Current.MainWindow.Top;
            window.Left            = App.Current.MainWindow.Left;
            App.Current.MainWindow = window;
            this.Close();
            window.Show();
        }