Quantcast
Channel: wpftoolkit Discussions Rss Feed
Viewing all articles
Browse latest Browse all 2157

New Post: PropertyGrid and UpdateSourceTrigger=PropertyChanged not working

$
0
0
Hi,

The Binding is on the SelectedObject, so UpdateSourceTrigger will be activated when the SelectedObject changes. But here, its a property from the SelectedObject that is changed. Here's what you could do :
<xctk:PropertyGrid x:Name="_propertyGrid"
                            SelectedObject="{Binding Blubber}">
            <xctk:PropertyGrid.EditorDefinitions>
               <xctk:EditorTemplateDefinition TargetProperties="ValidationTest">
                  <xctk:EditorTemplateDefinition.EditingTemplate>
                     <DataTemplate>
                          <!-- one option -->
                          <!--<TextBox Text="{Binding Value, UpdateSourceTrigger=PropertyChanged}" />-->
                          <!-- another option -->
                          <xctk:PropertyGridEditorTextBox Text="{Binding Value, UpdateSourceTrigger=PropertyChanged}" />
                     </DataTemplate>
                  </xctk:EditorTemplateDefinition.EditingTemplate>
               </xctk:EditorTemplateDefinition>
            </xctk:PropertyGrid.EditorDefinitions>
 </xctk:PropertyGrid>

Viewing all articles
Browse latest Browse all 2157

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>