public iTunesRatingControl(string artfolder, string[] stringsToRemove, string hashFile, string statsfile) : this() { _artfolder = artfolder; _stringsToRemove = stringsToRemove; _hashes = HashCollection.Load(hashFile); _hashFile = hashFile; _statsfile = statsfile; if (File.Exists(_statsfile)) { var lines = File.ReadAllLines(_statsfile); foreach (string line in lines) { var vals = line.Split('='); if (vals.Length != 2) { continue; } switch (vals[0].Trim().ToLower()) { case "1starcount": _ratingCounters[0] = int.Parse(vals[1]); break; case "2starcount": _ratingCounters[1] = int.Parse(vals[1]); break; case "3starcount": _ratingCounters[2] = int.Parse(vals[1]); break; case "4starcount": _ratingCounters[3] = int.Parse(vals[1]); break; case "5starcount": _ratingCounters[4] = int.Parse(vals[1]); break; } } } }