Beispiel #1
0
        public void SaveToFile()
        {
            string fn = "./Data/" + FundId.ToString() + "_" + DateTime.Now.ToString("yyyy-MM-dd-HH-mm-ss") + ".txt";

            Directory.CreateDirectory(Path.GetDirectoryName(fn));
            File.WriteAllText(fn, WebResponce);
        }
Beispiel #2
0
        public override string ToString()
        {
            string res = "";

            foreach (DayValue dv in DayValues)
            {
                res += FundId.ToString() + "," + dv.Date.ToString("yyyy/MM/dd", CultureInfo.InvariantCulture)
                       + "," + dv.Value.ToString(CultureInfo.InvariantCulture)
                       + "," + dv.Percent.ToString(CultureInfo.InvariantCulture)
                       + Environment.NewLine;
            }
            return(res);
        }