private void SetUpData() { try { ListMovimenti = new RegistryMovementTypeList(); ListGestioni = new RegistryOwnersList(); ListConti = new RegistryLocationList(); ListValute = new RegistryCurrencyList(); TipoSoldis = new TipoSoldiList(); RegistryMovementTypeList listaOriginale = new RegistryMovementTypeList(); listaOriginale = _registryServices.GetRegistryMovementTypesList(); var RMTL = from movimento in listaOriginale where (movimento.Id_tipo_movimento == (int)TipologiaMovimento.Cedola || movimento.Id_tipo_movimento == (int)TipologiaMovimento.InsertVolatili || movimento.Id_tipo_movimento == (int)TipologiaMovimento.Giroconto) || movimento.Id_tipo_movimento == (int)TipologiaMovimento.Costi || movimento.Id_tipo_movimento == (int)TipologiaMovimento.CambioValuta || movimento.Id_tipo_movimento == (int)TipologiaMovimento.AcquistoTitoli || movimento.Id_tipo_movimento == (int)TipologiaMovimento.VenditaTitoli select movimento; foreach (RegistryMovementType registry in RMTL) { ListMovimenti.Add(registry); } ListValute = _registryServices.GetRegistryCurrencyList(); RegistryOwnersList ListaInvestitoreOriginale = new RegistryOwnersList(); ListaInvestitoreOriginale = _registryServices.GetGestioneList(); var ROL = from gestione in ListaInvestitoreOriginale where (gestione.Tipologia == "Gestore") select gestione; _TabControl.TabStripPlacement = Dock.Left; foreach (RegistryOwner registryOwner in ROL) { // per ogni gestione acquisisco is dati per la sintesi soldi TabItem tabItem = new TabItem(); tabItem.Header = registryOwner.Nome_Gestione; tabItem.Content = new TabControlSintesiView(new TabControlSintesiViewModel(_liquidAssetServices.GetCurrencyAvailable(registryOwner.Id_gestione))); _TabControl.Items.Add(tabItem); ListGestioni.Add(registryOwner); } ListConti = _registryServices.GetRegistryLocationList(); TipoSoldis = _registryServices.GetTipoSoldiList(); SharesList = new ObservableCollection <RegistryShare>(_registryServices.GetRegistryShareList()); _Filter = new Predicate <object>(Filter); BirdsListView = _registryServices.GetSharesByFirms(typeOfShares); } catch (Exception err) { throw new Exception("Errore nel setup." + Environment.NewLine + err.Message); } }