private void msTiposDeportes_Click(object sender, EventArgs e) { FSportTypes fSportTypes = new FSportTypes(); fSportTypes.OnSearchMode = false; if (this.TopMost) fSportTypes.TopMost = true; fSportTypes.ShowDialog(); }
private void btnFindSportType_Click(object sender, EventArgs e) { FSportTypes fSportTypes = new FSportTypes(); fSportTypes.OnSearchMode = true; fSportTypes.ShowDialog(); if (fSportTypes.OnSearchMode) { txtSportTypeID.Text = Global.sportTypeUsed.SportTypeID.ToString(); fSportTypes.OnSearchMode = false; } }
private void btnFindSport_Click(object sender, EventArgs e) { FSportTypes fSportTypes = new FSportTypes(); fSportTypes.OnSearchMode = true; fSportTypes.ShowDialog(); if (fSportTypes.OnSearchMode) { Int64 aSportID = Global.sportTypeUsed.SportTypeID; //txtSportTypeName.Text = Global.sportTypeUsed.SportTypeName; fSportTypes.OnSearchMode = false; //Check if Sports yet exists on bd bool finded = false; finded = SportTypes.checkIfSportsIsInUserList(connString, aSportID, Global.userUsed.userID); if (!finded) { addSportTypeToList(connString, Global.userUsed.userID, aSportID); sportsChange = true; } else { MessageBox.Show("Ese deporte ya estaba en la lista."); } } }