Hello. I have a ControlTemplate (custom panel) and Im trying to add button with a style, but Studio returns exceptions "Cannot set resource 'RimButton'." But if I type this in XAML code of any page, it shows to me.
How can I fix this and use styled button in ControlTemplate?