2012-02-24 9 views
0

私は関連ViewSourceを観察するにはどうすればいいですか? WPF XAMLで

var aViewSource = (CollectionViewSource)this.FindResource("aViewSource"); 
var tableA = new ObservableCollection<TableA>(
    this.entities.TableA 
     .Where(predicate) 
     .Take(10) 
     .ToList()); 
tableA.CollectionChanged += this.NotifyCollectionChangedEventHandler; 
fibrasViewSource.Source = tableA; 

どのように私はanotherViewSourceを観察することができますがありxaml.csで

<CollectionViewSource 
    x:Key="aViewSource" 
    d:DesignSource="{d:DesignInstance my1:TableA, CreateList=True}" /> 
<CollectionViewSource 
    x:Key="anotherViewSource" 
    Source="{Binding Path=ANOTHER, Source={StaticResource aViewSource}}" /> 

がありますか?

答えて

0

私はViewSourceを使用しても利点がないので、私はViewSourceを完全に捨てました。

関連する問題