If you put style in app.xmal, then you can get the style with the code like:
Style = Application.Current.Resources["myStyle"] as Style;
But if I put style in a dictionary resource of a separate file Styles.xmal like:
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Assets/Styles.xaml"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Application.Resources>
Then how to get the style in code?