title: How to get updated automatically WPF TreeViewItems with values based on .Net class properties?
body: <p>Good morning. 
  I have a class with data derived from InotifyPropertyChange. The data come from a background thread, which searches for files with certain extension in certain locations. Public property of the class reacts to an event OnPropertyChange by updating data in a separate thread. Besides, there are described in XAML TreeView, based on HierarhicalDataTemplates. Each TextBlock inside templates supplied ItemsSource = "{Binding FoundFilePaths, Mode = OneWay, NotifyOnTargetUpdated = True}".</p>
  
  <pre><code> &lt;TreeView  x:Name="FoundFiles_TreeView"  Opacity="15" Background="White"   BorderThickness="5" FontFamily="Arial" Margin="0,0,0,0" RenderTransformOrigin="0.5,0.5" VerticalAlignment="Top" Height="360" FontWeight="Bold" Foreground="#FF539DBE" TargetUpdated="FoundFiles_TreeView_TargetUpdated"&gt;
              &lt;TreeView.ItemContainerStyle &gt;
                  &lt;Style TargetType="{x:Type TreeViewItem}"&gt;
                      &lt;Setter Property="TreeViewItem.Tag" Value="InfoNode" /&gt;
                      &lt;Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" /&gt;
                      &lt;Setter Property="Foreground" Value="Brown"/&gt;
                      &lt;Style.Triggers&gt;
                          &lt;Trigger Property="IsMouseCaptured" Value="True"&gt;
                              &lt;Setter Property="IsSelected" Value="True"/&gt;
                          &lt;/Trigger&gt;
                      &lt;/Style.Triggers&gt;
                  &lt;/Style&gt;
              &lt;/TreeView.ItemContainerStyle&gt;
              &lt;TreeView.Resources&gt;
                  &lt;HierarchicalDataTemplate  DataType = "{x:Type lightvedo:FilesInfoStore}"  ItemsSource="{Binding FoundFilePaths, Mode=OneWay, NotifyOnTargetUpdated=True}"&gt;
                      &lt;!--Здесь указываются узлы дерева--&gt;
                      &lt;StackPanel x:Name ="TreeNodeStackPanel" Orientation="Horizontal"&gt;
                          &lt;TextBlock Margin="5,5,5,5" TargetUpdated="TextBlockExtensions_TargetUpdated"&gt;
           &lt;TextBlock.Text&gt;
            &lt;MultiBinding StringFormat="Files with Extension  {0}"&gt;
             &lt;Binding Path="FileExtension"/&gt;
            &lt;/MultiBinding&gt;
           &lt;/TextBlock.Text&gt;
                          &lt;/TextBlock&gt;
                          &lt;Button x:Name="OpenFolderForThisFiles" Click="OnOpenFolderForThisFiles_Click" Margin="5, 3, 5, 3" Width="22" Background="Transparent" BorderBrush="Transparent" BorderThickness="0.5"&gt;
                              &lt;Image Source="images\Folder.png" Height="16" Width="20" &gt;
                              &lt;/Image&gt;
                          &lt;/Button&gt;
                      &lt;/StackPanel&gt;
                  &lt;/HierarchicalDataTemplate&gt;
                  &lt;HierarchicalDataTemplate DataType="{x:Type lightvedo:FilePathsStore}"&gt;
                      &lt;TextBlock Text="{Binding FilePaths, Mode=OneWay, NotifyOnTargetUpdated=True}" TargetUpdated="OnTreeViewNodeChildren_Update" /&gt;
                  &lt;/HierarchicalDataTemplate&gt;
              &lt;/TreeView.Resources&gt;
              &lt;TreeView.RenderTransform&gt;
                  &lt;TransformGroup&gt;
                      &lt;ScaleTransform/&gt;
                      &lt;SkewTransform AngleX="-0.083"/&gt;
                      &lt;RotateTransform/&gt;
                      &lt;TranslateTransform X="-0.249"/&gt;
                  &lt;/TransformGroup&gt;
              &lt;/TreeView.RenderTransform&gt;
              &lt;TreeView.BorderBrush&gt;
                  &lt;LinearGradientBrush EndPoint="1,0.5" StartPoint="0,0.5"&gt;
                      &lt;GradientStop Color="#FF74591F" Offset="0" /&gt;
                      &lt;GradientStop Color="#FF9F7721" Offset="1" /&gt;
                      &lt;GradientStop Color="#FFD9B972" Offset="0.49" /&gt;
                  &lt;/LinearGradientBrush&gt;
              &lt;/TreeView.BorderBrush&gt;
          &lt;/TreeView&gt;
  </code></pre>
  
  <p>Q: Why is the data from a class derived from INotifyPropertyChange does not affect the display of tree items. Do I understand: The interface will make INotifyPropertyChange be automatically redrawn TreeViewItems or do I need to manually carry out this operation? Currently TreeViewItems not updated and PropertyChamged always null. A feeling that no subscribers to the event OnPropertyChanged.</p>