Esempio n. 1
0
 // create button method/event
 private void CreateButtonClick(object sender, EventArgs e)
 {
     if (!TxtName.Text.Contains(" "))
     {
         TxtName.Text = "Must Enter Full Name!";
         TxtName.Focus();
     }
     else
     {
         customer1.Name           = TxtName.Text;
         customer1.InitialDeposit = double.Parse(TxtInitialDeposit.Text);
         customer1.accountNumberGenerate();
         TxtInitialDeposit.Text     = customer1.convertDeposit();
         AccountTxtBox.Text         = customer1.AccountNumber.ToString();
         TxtName.Enabled            = false;
         TxtInitialDeposit.ReadOnly = true;
         AccountLbl.Show();
         AccountTxtBox.Show();
         lblDeposit.Show();
         TxtDeposit.Show();
         TxtDeposit.Focus();
         lblWithDraw.Show();
         TxtWithdraw.Show();
         UpdateAccountButton.Show();
         CreateButton.Hide();
         TxtDeposit.Focus();
     }
 }
Esempio n. 2
0
 /*************************** Game Lobby **************************************
  * initializes the lobby and allows only the exit button and the login button the
  * be available before connecting to the server.
  */
 public gameLobby()
 {
     InitializeComponent();
     CreateButton.Hide();
     ListGamesButton.Hide();
     JoinButton.Hide();
     SendButton.Hide();
     this.AcceptButton = SendButton;
 } // end of gameLobby
Esempio n. 3
0
        public Form1()
        {
            InitializeComponent();

            label1.Hide();
            listBox1.Hide();
            CreateButton.Hide();
            UpdateButton.Hide();
            DeleteButton.Hide();

            db = new AcademyEntities();

            /*db.Curators.Load();
             *
             * dataGridView1.DataSource = db.Curators.Local.ToBindingList();*/


            /*  var tableNames = db.MetadataWorkspace.GetItems(DataSpace.SSpace)
             *            .Select(t => t.Name)
             *            .ToList();
             * DbSet dbSet = db.;*/
        }