Skip to main content
added 1 character in body
Source Link
EldHasp
  • 8.7k
  • 2
  • 11
  • 33

I'm suggesting a variation based on the XAML you provided of the UserControl's DataContext binding:

 <TextBlock Text="{Binding SettingUserEdit.ApplicationVersion, Source={StaticResource Locator}}" /> 

I did not quite understand why you declared the DataContext binding for the UserControl in this way. Locator is declared in Resources either in App (recommended option) or in Window.
In both cases, the binding can be written as:

<UserControl ------------------------- ------------------------- DataContext="{Binding SettingUserEdit, Source={StaticResource Locator}}"> 

I'm suggesting a variation based on the XAML you provided of the UserControl's DataContext binding:

 <TextBlock Text="{Binding SettingUserEdit.ApplicationVersion, Source={StaticResource Locator}" /> 

I did not quite understand why you declared the DataContext binding for the UserControl in this way. Locator is declared in Resources either in App (recommended option) or in Window.
In both cases, the binding can be written as:

<UserControl ------------------------- ------------------------- DataContext="{Binding SettingUserEdit, Source={StaticResource Locator}"> 

I'm suggesting a variation based on the XAML you provided of the UserControl's DataContext binding:

 <TextBlock Text="{Binding SettingUserEdit.ApplicationVersion, Source={StaticResource Locator}}" /> 

I did not quite understand why you declared the DataContext binding for the UserControl in this way. Locator is declared in Resources either in App (recommended option) or in Window.
In both cases, the binding can be written as:

<UserControl ------------------------- ------------------------- DataContext="{Binding SettingUserEdit, Source={StaticResource Locator}}"> 
Source Link
EldHasp
  • 8.7k
  • 2
  • 11
  • 33

I'm suggesting a variation based on the XAML you provided of the UserControl's DataContext binding:

 <TextBlock Text="{Binding SettingUserEdit.ApplicationVersion, Source={StaticResource Locator}" /> 

I did not quite understand why you declared the DataContext binding for the UserControl in this way. Locator is declared in Resources either in App (recommended option) or in Window.
In both cases, the binding can be written as:

<UserControl ------------------------- ------------------------- DataContext="{Binding SettingUserEdit, Source={StaticResource Locator}">