private void UpdateSymbolsFromDB()
        {
            IList <OptionProcessingService.Types.SymbolNew> symbollist = DB.GetSymbolsNew();

            foreach (var dbsymbol in symbollist)
            {
                textSymbol.Text = dbsymbol.ShortName;
                //TimestampUtility.BuildSymbolName(dbsymbol.ShortName, dbsymbol.Type == SecurityType.Forex ?
                //CommonObjects.Unitity.Instrument.Forex : CommonObjects.Unitity.Instrument.Equity);
                ddfplus.Symbol symbol          = new ddfplus.Symbol(textSymbol.Text);
                bool           doubleDigitYear = (symbol.Type == ddfplus.Symbol.TypeConstants.Future) && char.IsDigit(symbol.Name[symbol.Name.Length - 2]);
                if (!doubleDigitYear || (MessageBox.Show("Only single-digit years are supported in the feed for futures contracts.\n"
                                                         + "Would you still like to use this symbol?", Application.ProductName, MessageBoxButtons.OKCancel, MessageBoxIcon.Exclamation)
                                         == DialogResult.OK))
                {
                    AddSymbol(textSymbol.Text,
                              checkInitialRefresh.Enabled && checkInitialRefresh.Checked,
                              checkStreamingData.Enabled && checkStreamingData.Checked,
                              checkBookRefresh.Enabled && checkBookRefresh.Checked,
                              checkBookUpdates.Enabled && checkBookUpdates.Checked,
                              checkOHLCMinuteBars.Enabled && checkOHLCMinuteBars.Checked);
                }
            }
        }
 private void UpdateSymbols()
 {
     try
     {
         ddfplus.Symbol symbol          = new ddfplus.Symbol(textSymbol.Text);
         bool           doubleDigitYear = (symbol.Type == Symbol.TypeConstants.Future) && char.IsDigit(symbol.Name[symbol.Name.Length - 2]);
         if (!doubleDigitYear || (MessageBox.Show("Only single-digit years are supported in the feed for futures contracts.\n"
                                                  + "Would you still like to use this symbol?", Application.ProductName, MessageBoxButtons.OKCancel, MessageBoxIcon.Exclamation)
                                  == DialogResult.OK))
         {
             AddSymbol(textSymbol.Text,
                       checkInitialRefresh.Enabled && checkInitialRefresh.Checked,
                       checkStreamingData.Enabled && checkStreamingData.Checked,
                       checkBookRefresh.Enabled && checkBookRefresh.Checked,
                       checkBookUpdates.Enabled && checkBookUpdates.Checked,
                       checkOHLCMinuteBars.Enabled && checkOHLCMinuteBars.Checked);
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(string.Format("Error updating symbols: {0}", ex.Message),
                         Application.ProductName, MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
     }
 }