/// <summary> /// Initialization of market data providers /// </summary> private async void InitializeMarketDataProviders() { MarketDataProviders.Clear(); // Request Controller for infomation var availableProviders = await Task.Run(() => _providersController.GetAvailableMarketDataProviders()); // Safety check incase information was not populated if (availableProviders == null) { return; } // Populate Individual Market Data Provider details to show on UI foreach (var provider in availableProviders) { // Add to Collection MarketDataProviders.Add(provider); } // Select initially 1st provider in ComboBox if (_marketDataProviders != null && _marketDataProviders.Count > 0) { SelectedMarketDataProvider = _marketDataProviders[0]; } }
/// <summary> /// Populate market data provider names /// </summary> private void PopulateMarketDataProviders() { // Clear any existing values MarketDataProviders.Clear(); // Populate Individual Market Data Provider Details foreach (var provider in ProvidersController.MarketDataProviders) { // Add to Collection MarketDataProviders.Add(provider.ProviderName); } }