protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);

            // Create your application here
            SetContentView(Resource.Layout.EditDatabase);

            SqlConnection mySqlConnectionClass = new SqlConnection(); // Sql Connection

            myList = mySqlConnectionClass.ViewAll();

            btnEditDbBackToMainMenu        = FindViewById <Button>(Resource.Id.btnEditDbBackToMainMenu); // 1.button back to main menu
            btnEditDbBackToMainMenu.Click += btnEditDbBackToMainMenu_Click;

            btnDeleteEntry         = FindViewById <Button>(Resource.Id.btnDeleteEntry); // 2. Button Delete
            btnDeleteEntry.Click  += btnDeleteEntry_Click;
            btnDeleteEntry.Enabled = false;

            spinnerEditDB = FindViewById <Spinner>(Resource.Id.spinnereditDB);
            Resources.DataAdapterFile dtadptr = new Resources.DataAdapterFile(this, myList);   // 3. Spinner dropdown

            spinnerEditDB.Adapter = dtadptr;

            spinnerEditDB.ItemSelected += new EventHandler <AdapterView.ItemSelectedEventArgs>(spinnerEditDB_ItemSelected);
        }
        protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);

            // Create your application here
            SetContentView(Resource.Layout.AddPlayerProfile);

            SqlConnection mySqlConnectionClass = new SqlConnection();

            myList = mySqlConnectionClass.ViewAll();

            SelectPlayerSpinner = FindViewById <Spinner>(Resource.Id.selectPlayerSpinner); //Palyer dropdown
            DataAdapterFile dtadptr = new Resources.DataAdapterFile(this, myList);

            SelectPlayerSpinner.Adapter = dtadptr;

            SelectPlayerSpinner.ItemSelected += new EventHandler <AdapterView.ItemSelectedEventArgs>(SpinnerDropdown_ItemSelected);

            txtEnterPlayerName = FindViewById <TextView>(Resource.Id.txtEnterName); //Enter Player name textview

            Button btnAddPlayer = FindViewById <Button>(Resource.Id.btnAddProfile); //button Add Player Profile

            btnAddPlayer.Click += btnAddPlayer_Click;

            Button btnGobackToMainMenu = FindViewById <Button>(Resource.Id.btnGobackToMainMenu);

            Button btnStartGame = FindViewById <Button>(Resource.Id.btnStartGame); //button Start Game

            btnStartGame.Click += btnStartGame_Click;

            btnGobackToMainMenu.Click += btnGobackToMainMenu_Click;  //button back to Main Menu
        }
        private void btnDeleteEntry_Click(object sender, EventArgs e)
        {
            var sqlConn = new SqlConnection();

            sqlConn.DeletePlayer(HangmanGameActivity.Id);
            myList = sqlConn.ViewAll();

            var dtadptr = new Resources.DataAdapterFile(this, myList);

            spinnerEditDB.Adapter = dtadptr;
        }
        private void btnAddPlayer_Click(object sender, EventArgs e) //Button_click Add Player
        {
            if (txtEnterPlayerName.Text.Length > 0)                 // If word length is > 0 do this else display msg
            {
                HangmanGameActivity.PlayerName = txtEnterPlayerName.Text.ToString();
                HangmanGameActivity.score      = 0; // Start score @ 0.

                var sqlConn = new SqlConnection();
                sqlConn.InsertNewPlayer(HangmanGameActivity.PlayerName, HangmanGameActivity.score); // Inserts the Players name and score

                myList = sqlConn.ViewAll();                                                         // update the list

                var dtadptr = new Resources.DataAdapterFile(this, myList);                          //DataAdapterFile.cs
                SelectPlayerSpinner.Adapter = dtadptr;                                              //displays the updated list on the spinner

                Toast.MakeText(this, "Add Sucessful!", ToastLength.Short).Show();
            }
            else
            {
                Toast.MakeText(this, "Please Enter A Valid Name!", ToastLength.Short).Show(); // Toast(view) ie: displays message
            }
        }