I have a binary Silverlight control (some box with a custom content). Now I want do add a title on the top of that control. When I create a custom silverlight control and try to inherit the binary then I don’t know how to add the title in XAML. Is it possible? I know that I can create a custom control that can have TextBlock and the binary inside. But I work in the fairly big project and there will be too many changes needed. In my case (if it’s possible) I’d only change the control name in XAML from MyBinaryControl into MyBinaryControlExtended:)
Thx for any help.
For custom controls you need to set up a new default
Stylewith aTemplateinThemes/Generic.xaml, this means that in case of inheritance you need to get the new default template and incorporate it there.If you create a
UserControllike that and create and bind all the needed dependency properties that will not be any more work than the custom control case. Also you do not need to copy the whole template.