Tag Info

Hot answers tagged

4

Please check the following: Is there any warning in the ULS-logs? Is the sequence set correctly? Does adding a breakpoint help (this checks if the code is actually loaded) Check if the Control is referenced at all in the page using http://blog.mastykarz.nl/checking-which-delegate-controls-activated-site/ ? Is the control registered as safe (check in the ...


4

The line <Property Name="QueryPromptString">$Resources:MyResourceFile,ResourceKey</Property> wokrs fine for me. I think that you should check your resources file. This file should contain ResourceKey which you tries to use in this property. If you use correct resource file and key, the search control displays text depends on the site language. ...


3

Here's a complete example of a working ASCX SharePoint DelegateControl. It adds the required Google Analytics stuff plus any meta keywords you define. First, the feature.xml: <Feature Id="INSERTYOURGUIDHERE" Title="Adds Google Analytics Counter (requires a Google Analytics ID)" Description="Activates feature for Google Analytics Web counter" ...


2

You can develop a Delegate Control for the Head Section, by creating a SharePoint feature. That SharePoint feature can be enabled and disabled according to the Sites. File -> New Project -> SharePoint Empty Project. Add New Class and change its base class to System.Web.UI.WebControls.WebControl Override required methods like OnLoad,CreateChildControls or ...


2

In feature 1 have an elements.xml with: <?xml version="1.0" encoding="utf-8"?> <Elements xmlns="http://schemas.microsoft.com/sharepoint/"> <Control Id="AdditionalPageHead" Sequence="90" ControlSrc="~/_CONTROLTEMPLATES/XXX/first.ascx" /> </Elements> In feature 2 have an elements.xml with: ...


2

Where exactly do you want the webpart to show up? If you put it in the master page, it will show up everywhere. Usually this is not what you want with controls like CQWP. Your options also depend on how you provision your solution. The recommended approach is to use module features and solutions for master pages, page layouts and pages. If this is how ...


1

I guess one way to do this would be to iterate over all the feature definitions in the Farm looking for the relevant elements defintions. I recall needing to do something like that when I needed to list all Custom Actions. As the points above state, all the info can be seen using the reflector/ILSpy and you'll need to write your own versions.


1

Try using ScriptLink <sharepoint:scriptlink defer="false " id="SPScriptLink " localizable="false " name="jquery-x.x.x.js " runat="server"></sharepoint:scriptlink> or <SharePoint:Scriptlink runat="server" Name="~sitecollection/Style Library/[YOUR SITE]/js/jquery.js" Language="javascript" /> The ScriptLink control ensures that the ...


1

Opening up the "DelegateControl" object in Reflector it is basically just a dynamic control builder. It queries the current context to get the list of all registered controls (i.e. features with a <Control> element which uses the same ControlId as the Delegate Control). These could be features from any of the available scopes (Farm, Web Application, ...


1

I always have added custom links to the suite bar using a small jquery script on the page On SharePoint 2013 you can do that using this code <script type="text/javascript"> var suiteBar = $("#suiteBar").find(".ms-core-brandingText"); suite.html("<a href="www.google.com"> custum link </a>"); </script> If you are using Office 365 ...


1

I think, given that the changes are 'global', you could simply use a list to store them, at root level. So on the root level of your sharepoint site, create a list (that you hide from navigation etc), with a content type that has all the fields you need to store. Then, when the user 'saves changes' from your custom page (or control), that list is updated ...


1

I had similar requirements and I preferred to store custom settings for each user in a hidden list called user info list. More information about this list here: http://zimmergren.net/technical/sharepoints-hidden-user-list-user-information-list I extended the list by adding an extra column to store the user settings.


1

You can use SPPersistedObject which stores data in Configuration database. I have written a blog post which shows how to use SPPersistedObject in admin pages in SharePoint. This may give you some pointers on how to use it in your page. http://sharepointnadeem.blogspot.in/2012/03/create-administration-page-in.html


1

Delegate Controls are activated by FEATURES. So you need to find a FEATURE that contains the definition of Delegate Cotrol. And for you its the feature ‘My Site Navigation’ which is located in {SharePointRoot}\TEMPLATE\FEATURES\MySiteNavigation\Feature.xml. If you observe the element file of that FEATURE, you will see that the top navigation corresponds ...


1

I think CQWP is possibly the wrong route as it doesn't work across site collections, only within a single site collection. It sounds like you're better off looking at creating a custom Data Source, adding that into your web.config and replacing the existing navigation delegates using a feature. Much simpler in the long run. Without knowing more about ...


1

What I have done in a situation like this in past is created a custom web control and override the CreateChildControls method. In this method you would create instance of your WebPart and programmatically configure the the webpart to match it with your .webpart file and add web part to the Controls collection of your control. Now that you have a control you ...



Only top voted, non community-wiki answers of a minimum length are eligible