예제 #1
0
        private void ParseFundTable(string responseFromServer)
        {
            IList fundTableLines = new ArrayList();

            var parsedStrings = responseFromServer.Split('\n');

            fundTableLines.Clear();
            foreach (var line in parsedStrings)
            {
                if (line.IndexOf("</option>", StringComparison.Ordinal) != -1)
                {
                    fundTableLines.Add(line);
                }
            }

            for (var count = 0; count < 5; count++)
            {
                if (fundTableLines.Count > 0)
                {
                    fundTableLines.RemoveAt(0);
                }
            }

            FundTable.Clear();
            foreach (string line in fundTableLines)
            {
                var chunks = line.Split('\"', '>', '<');
                FundTable.Add(chunks[4], chunks[2]);
            }
        }
예제 #2
0
        public void InitializeFundTable()
        {
            PriceServer.GetFundTable();

            FundTable.Clear();
            foreach (var(key, value) in PriceServer.FundTable)
            {
                FundTable.Add(key, value);
            }

            RemoveMoneyMarketFunds();
        }