private void NextButton_Click(object sender, RoutedEventArgs e)
        {
            string selected = comboBox.SelectedItem.ToString();
            int    index    = lst.FindIndex(a => a == selected);

            switch (index)
            {
            case 0:
                Report1Window.GetInstance().Show();
                this.Close();
                break;

            case 1:
                Report2Window.GetInstance().Show();
                this.Close();
                break;

            case 2:
                Report3Window.GetInstance().Show();
                this.Close();
                break;

            case 3:
                Report4Window.GetInstance().Show();
                this.Close();
                break;

            case 4:
                Report5Window.GetInstance().Show();
                this.Close();
                break;
            }
        }
示例#2
0
 public static Report5Window GetInstance()
 {
     if (instance == null)
     {
         instance = new Report5Window();
     }
     return(instance);
 }
示例#3
0
 private void Window_Unloaded(object sender, RoutedEventArgs e)
 {
     instance = null;
 }