public CSVReader(string fileName) { var csvreader = new CSVReader(); if (!File.Exists(fileName)) throw new Exception("Failed to find file: " + fileName + "!"); var reader = new StreamReader(File.OpenRead(AppDomain.CurrentDomain.BaseDirectory +"\\" + fileName)); while (!reader.EndOfStream) { var line = reader.ReadLine(); var values = line.Split(','); _data.Add(values[0].Trim(), values[1].Trim()); } }
public UIControlSet(string controlSetName) { _reader = new CSVReader(controlSetName + ".csv"); }