示例#1
0
        private void login_btn_Click(object sender, RoutedEventArgs e)
        {
            if (this.LoginValidate(this.username_txt.Text, this.password_txt.Password))
            {
                Users _users = new Users();
                List<Users> _data = this._userController.GetSingleUserData(this.username_txt.Text, this.password_txt.Password);

                foreach (var _row in _data)
                {
                    _users = _row;
                }

                MainFrm _mainFrm = new MainFrm(_users.user_id, _users.user_name);
                this.Close();
                _mainFrm.Show();
            }

        }
示例#2
0
 void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) {
     switch (connectionId)
     {
     case 1:
     this.windowUtama = ((simplenoodle.MainFrm)(target));
     return;
     case 2:
     this.gridLuar = ((System.Windows.Controls.Grid)(target));
     return;
     case 3:
     this.gridDalamKiri = ((System.Windows.Controls.Grid)(target));
     return;
     case 4:
     this.strCust_btn = ((System.Windows.Controls.Button)(target));
     
     #line 10 "..\..\MainFrm.xaml"
     this.strCust_btn.Click += new System.Windows.RoutedEventHandler(this.strCust_btn_Click);
     
     #line default
     #line hidden
     return;
     case 5:
     this.strSales_btn = ((System.Windows.Controls.Button)(target));
     
     #line 11 "..\..\MainFrm.xaml"
     this.strSales_btn.Click += new System.Windows.RoutedEventHandler(this.strSales_btn_Click);
     
     #line default
     #line hidden
     return;
     case 6:
     this.strInv_btn = ((System.Windows.Controls.Button)(target));
     
     #line 12 "..\..\MainFrm.xaml"
     this.strInv_btn.Click += new System.Windows.RoutedEventHandler(this.strInv_btn_Click);
     
     #line default
     #line hidden
     return;
     case 7:
     this.strInvTicktab_btn = ((System.Windows.Controls.Button)(target));
     
     #line 13 "..\..\MainFrm.xaml"
     this.strInvTicktab_btn.Click += new System.Windows.RoutedEventHandler(this.strInvTicktab_btn_Click);
     
     #line default
     #line hidden
     return;
     case 8:
     this.gridDalamKanan = ((System.Windows.Controls.Grid)(target));
     return;
     case 9:
     this.CustomerCtrl = ((simplenoodle.CustomerUc)(target));
     return;
     case 10:
     this.SalesCtrl = ((simplenoodle.SalesUc)(target));
     return;
     case 11:
     this.InvoiceCtrl = ((simplenoodle.InvoiceUc)(target));
     return;
     case 12:
     this.InvoiceTicktabCtrl = ((simplenoodle.InvoiceTicktabUc)(target));
     return;
     }
     this._contentLoaded = true;
 }