I have this XAML:
<MenuItem Name="celsiusBtn"
Header="{Binding Path=celsiusBtn, Source={StaticResource Resources}}"
IsChecked="True"
Click="celsiusBtn_Click" />
I'm using this to bind string and be able to change them at runtime:
Now my problem is I need to do the same binding in code, but I don't know how to specify the Source in the Binding. I know I can give the Path or the property name in the constructor of the class, but I'm unsure on how to access the Source property or even to define it to the StaticResource.