Tagged Questions
0
votes
1answer
25 views
Execute SPFeatureReceiver only on site creation
We have recently upgraded from SharePoint 2007 to 2010 and we aren't yet ready to train users on the new interface, so I've created a SPFeatureReceiver that will set the site template back to the 2007 ...
0
votes
1answer
51 views
Enable-SPFeature doesn't work, but activation via Site Settings does. Why?
I have a weird problem... I'm trying to deploy a sharepoint solution in production. This project works fine in the test environment, but in production trying to enable the feature returns this error:
...
0
votes
0answers
76 views
SPUtility.GetLocalizedString not working in feature receiver when deployed from Visual Studio
I use SPUtility.GetLocalizedString in FeatureActivated method of a feature receiver to add a label to a custom action on a specific list instance.
When activating feature from SharePoint or ...
1
vote
1answer
25 views
Strange issue with feature activation
I'm having a problem while activating a feature. I have a custom dll that I referenced in this new project, and I'm trying to execute some code on the feature activation. The problem is that I get the ...
0
votes
1answer
38 views
Activating a WebApplication scoped feature on a single web app touches all web app web.configs
I have a WebApplication scoped feature, and I have set ActivateOnDefault to false, to prevent the feature from being activated on every web application when installed.
The feature is a simple ...
0
votes
1answer
26 views
error creating blog subsite in code
Im creating a blog subsite in the featureactivated event but it errors out everytime i activate the feature. looking at the logs i can see there is an access denied entry however the blog subsite is ...
1
vote
1answer
57 views
Does the SPField.OnAdded() method get called from a CAML deployment?
If I create a custom list definition and instance in CAML, as part of a feature, and I have included a custom field as part of that list, will that field's OnAdded() method get called when the feature ...
2
votes
1answer
109 views
SPListCollection.EnsureSitePagesLibrary() throwing SPException (specified title already exists in this Web site)
I am attempting to call SPListCollection.EnsureSitePagesLibrary() upon FeatureActivated. The method is throwing the following exception:
Microsoft.SharePoint.SPException: A list, survey, ...
1
vote
1answer
193 views
Can't find WebApplication scoped feature
I've deployed a wsp that has 2 features. The one scoped at a web level is listed where I'd expect to see it and activates without a problem. The feature scoped at a web application can't be found ...
0
votes
1answer
54 views
Convert site to a publishing site
I need to activate publishing features on certain sites without losing their site content (lists and libraries). The publishing feature is activated in site collection. When I try to activate the ...
0
votes
4answers
657 views
How to programmatically get Feature ID?
In order to programmatically activate a feature, you need its Feature ID (some type of GUID) that is set in the .feature file. Is there a pretty way of retrieving this value programmatically, so that ...
0
votes
1answer
1k views
Failed to load receiver assembly when activate feature
I have a problem when activating a Site scoped feature. Every time I try to activate the solution with STSADM or Powershell I get this error:
C:\Program Files\Common Files\Microsoft Shared\Web Server ...
1
vote
3answers
309 views
How to activate feature in a custom site
I have created a publishing web template. Now I need to activate a feature once the site is provisioned.
In order to achieve this, I've created an event receiver with something like this:
public ...
0
votes
2answers
213 views
Web-scoped Feature falsely activated during Visual Studio deployment
In Visual Studio I have a solution containing two features with their Scope set to "Web". These two features work as expected but the only thing that is going "wrong" is that they are activated when I ...
0
votes
1answer
79 views
Problem activating feature on child webs
I have a feature that is manually activated. In a feature receiver I also activate the feature on any child SPWebs in existence. I would like some code to run only on the SPWeb where the feature is ...
0
votes
0answers
24 views
Custom delegate is applied even if the feature is deactivated
I have a question regarding a feature.
Situation:
I have a feature that is farm scoped, with this feature I deploy a delegate control (xml file), this file refers to cs code.
So I've added that file ...
3
votes
1answer
172 views
Site Scope Feature dependent on a Web Scope Feature
On the root web for my site collection I need to make sure a web scope feature is turned on. In the feature EventReceiver I can turn on the feature progamtically. How can I stop the user turning the ...
1
vote
2answers
1k views
Feature not activated by default
I have a SP2010 wsp that contains multiple features all are scoped "web" all was working fine. But suddenly one of the feature stopped activating by default on deployment though all other features are ...
1
vote
2answers
523 views
Problem Setting Item Level Permissions Dynamically
I am working with SharePoint 2010 feature receivers. On feature activation I am creating multiple web part pages in library "Site Pages". I want to set individual permissions for each page, but I want ...
1
vote
2answers
2k views
Microsoft SharePoint is not supported with version 4.0.30319.225 of the Microsoft .Net Runtime
So, the story is the following:
I just joined a team of an existing sharepoint project, sharepoint is installed RTM on all environments, from DEV to production.
But because its 2 companies working ...
3
votes
2answers
446 views
Unable to delete List during solution deactivate
I have two list that I need to delete when a solution is deactivated and removed. But my code doesn't seems to be working. I am trying to delete and remove the quicklinks to the lists in ...
2
votes
2answers
907 views
List Instances not created on Feature Activation for Initial Deployment
I have two features, a Content Type feature that contains the content type and list definitions, and a List feature that creates the List Instances from the list definitions. Both features ...
0
votes
3answers
671 views
Cant´t activate a custom feature with PowerShell but with the GUI
I want to activate a custom feature with PowerShell on a few sites in my environment.
When I´m doing this job over the GUI, everything is perfect.
But when I´, doing it with my script, the feature ...
0
votes
2answers
426 views
Errors when attempting to install a sharepoint 2010 feature
I'm attempting to install and activate a feature containing a Timer Job. When I execute the install-spfeature cmdlet I get the following error. What is the source of my error?
PS ...
1
vote
1answer
468 views
removing a sharepoint solution duplicates entry in web.config?
My intentions is to be able to add and remove web.config changes when a solution is installed or uninstalled.
The code below and the powershell below works ALMOST as expected.
When I add sp ...
1
vote
1answer
120 views
What to do on feature deletion/deactivation
as I am trying to wrap my head around silverlight and sharepoint there's one thing I find most irritating: Provisioned xap-Files and/or web-Parts remain fully active upon deactivation/uninstallation ...
3
votes
1answer
1k views
Activate a feature in feature installed
I have a feature for deploying masterpages that I am trying to activate upon install(deploy). The following snippets of code are in the EventReceiver.cs. I am getting a null when attempting to ...
1
vote
1answer
237 views
Creating Site Templates - Master Page Not Being Handled Right After Upgrade
In our old MOSS 2007 farm we had a branding feature deployed that swapped out CSS Files, Master Pages, etc for our sites to keep a consistent branding across our Site Collections. We are currently in ...
