How do I make delegate controls?
I have followed several blogs and videos on creating delegate controls as the one I deployed is not being displayed on masterpage.
I created an entry in seattle.master as
<SharePoint:DelegateControl runat="server" ControlId="MyCustomDelegateControl" AllowMultipleControls="true"/>
I then added a usercontrol in visual studio 2012 which has a label with some text.
I added an empty element file to a feature scoped at sitecollection level. The element file contains
<?xml version="1.0" encoding="utf-8"?><Elements xmlns="http://schemas.microsoft.com/sharepoint/"><Control Id="MyCustomDelegateControl" Sequence="10" ControlSrc="~/_CONTROLTEMPLATES/BreakingNews.ascx"/></Elements>
I deployed it and saw the feature was installed in controltemplates of 15 hive and also it is activated but it is not displayed on the masterpage. The elements.xml file is also deployed in Features folder under my feature.
For the sake of testing, I registered the usercontrol on the masterpage with @Register tag and added it to the page , it displays then.
So can somebody tell me why it's not getting injected into the masterpage through delegate control?