public SearchResultPickerViewModel(LookupContext lookup)
        {
            LookupResultList = lookup.Results;
            //RaisePropertyChanged("LookupResultList");

            ErrorMessage = lookup.FailureMessage();
            SearchFailed = !String.IsNullOrEmpty(ErrorMessage);
            if (SearchFailed)
            {
                SearchText = lookup.Query;
            }

            QueryTitle = lookup.Query;

            SearchCommand       = new RelayCommand(RetrySearch);
            PickSelectedCommand = new RelayCommand(PickSelected);

            SelectedItem = LookupResultList.FirstOrDefault();
        }
Exemplo n.º 2
0
 public MainViewModel()
 {
     this._queryResult      = new LookupResultList();
     this._MarketDataSource = new MarketAPI();
 }