Ejemplo n.º 1
0
        // Button event handler for opening Add Train form
        private void btnAddTrain_Click(object sender, RoutedEventArgs e)
        {
            AddTrain frmAddTrain = new AddTrain();

            frmAddTrain.ShowDialog();
        }
Ejemplo n.º 2
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.AddTrain1 = ((RailwayPlanningSystem.AddTrain)(target));

            #line 8 "..\..\AddTrain.xaml"
                this.AddTrain1.Loaded += new System.Windows.RoutedEventHandler(this.Window_Loaded);

            #line default
            #line hidden
                return;

            case 2:
                this.comboDeparture = ((System.Windows.Controls.ComboBox)(target));

            #line 18 "..\..\AddTrain.xaml"
                this.comboDeparture.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboDeparture_SelectionChanged);

            #line default
            #line hidden
                return;

            case 3:
                this.comboDestination = ((System.Windows.Controls.ComboBox)(target));

            #line 22 "..\..\AddTrain.xaml"
                this.comboDestination.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboDestination_SelectionChanged);

            #line default
            #line hidden
                return;

            case 4:
                this.comboType = ((System.Windows.Controls.ComboBox)(target));

            #line 26 "..\..\AddTrain.xaml"
                this.comboType.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboType_SelectionChanged);

            #line default
            #line hidden
                return;

            case 5:
                this.stackIntermediates = ((System.Windows.Controls.StackPanel)(target));
                return;

            case 6:
                this.chkNewcastle = ((System.Windows.Controls.CheckBox)(target));
                return;

            case 7:
                this.chkDarlington = ((System.Windows.Controls.CheckBox)(target));
                return;

            case 8:
                this.chkYork = ((System.Windows.Controls.CheckBox)(target));
                return;

            case 9:
                this.chkPeterborough = ((System.Windows.Controls.CheckBox)(target));
                return;

            case 10:
                this.dateDepartureDay = ((System.Windows.Controls.DatePicker)(target));
                return;

            case 11:
                this.comboDepartureTime = ((System.Windows.Controls.ComboBox)(target));
                return;

            case 12:
                this.rdoSleeperYes = ((System.Windows.Controls.RadioButton)(target));
                return;

            case 13:
                this.rdoSleeperNo = ((System.Windows.Controls.RadioButton)(target));
                return;

            case 14:
                this.rdoFirstClassYes = ((System.Windows.Controls.RadioButton)(target));
                return;

            case 15:
                this.rdoFirstClassNo = ((System.Windows.Controls.RadioButton)(target));
                return;

            case 16:
                this.btnAddTrain = ((System.Windows.Controls.Button)(target));

            #line 47 "..\..\AddTrain.xaml"
                this.btnAddTrain.Click += new System.Windows.RoutedEventHandler(this.btnAddTrain_Click);

            #line default
            #line hidden
                return;
            }
            this._contentLoaded = true;
        }