//Check IDs in file and see if the specified ID is already in the file private bool alreadyFavourite(int id) { return(DataUtilities.GetFavouriteCityIDsFromDB(user.Username).Any(_id => _id == id)); }
private void Window_Loaded(object sender, RoutedEventArgs e) { grdMain.Background = DataUtilities.ChooseBackground(); //Randomly select background loggedInUser = new User(); txtUsername.Focus(); }