Defines methods that are called when a Feature is installed, uninstalled, activated, deactivated, or upgraded.

learn more… | top users | synonyms

0
votes
1answer
118 views

Hooking feature reciever issue

I have invalidly hooked feature reciever. Feature has two configuration files The first, SharePoint looks like this: < feature ...
2
votes
2answers
5k views

Failed to load reciever assembly

I have issue during deployment. It throws: Failed to load reciever assembly I tried to GAC that assembly, also microsoft.office.sharepoint.clientextensions.dll and Microsoft.Office.Server.dll ...
0
votes
1answer
145 views

Using a feature receiver to add a directory to the web applications folder

Wondering if someone knows how to add a directory/folder to the web applications folder within IIS using a feature event receiver (FeatureActivated). Any help appreciated.
5
votes
3answers
7k views

Best method to create custom NewForm / EditForm

I am new to sharepoint development and need to create some custom NewForm/EditForms for a new custom list I am creating. It seems like I have two choices: ...
1
vote
1answer
365 views

How Do I Rename a List Instance's Field's StaticName in FeatureUpdating?

I am creating a custom WSP in Visual Studio. This solution has several custom content types with custom fields as well as a list instance with content types enabled. Unfortunately, i need to change ...
0
votes
1answer
353 views

SharePoint 2010: Register InfoPath forms and use custom feature reciver jointly

I am new to SharePoint, sorry if answer to my question is obvious. I am using Custom InfoPath Task Forms in my project. For form registering, I am using next code in Feature.Template.xml: <?xml ...
0
votes
2answers
236 views

How can I pass an argument to a FeatureReceiver during solution setup?

I have this Sharepoint 2010 solution containing 3 projects: Class Library with Model classes Class Library with LINQ to SQL data context Sharepoint 2010 project WCF REST service 3 Visual web parts ...
1
vote
1answer
645 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 ...
5
votes
3answers
5k views

FeatureActivated event receiver giving access denied when trying so set WebApplication property

When a Site event feature is activated I am trying to set some properties on the web application. My feature uses this value. public override void FeatureActivated(SPFeatureReceiverProperties ...
0
votes
1answer
177 views

Object reference not set on Feature Receiver in a Stapled feature

SharePoint 2010 question. My 1st goal is to add some custom themes to site collections when they're created. I have this working with a simple 2 feature stapling solution (Themes.Feature, ...
3
votes
2answers
307 views

Error on feature activated property creation

Im trying to create custom properties on feature activated event, but it doenst work, does anyone has any suggestion, what the problem could be? When i do a console application and try there my code ...
2
votes
2answers
773 views

Preventing alerts from being sent when programmatically updating list item

I have a feature receiver which batch updates a particular field / column in my list. Code is provided below. NB: This is very simple list item batch processing code which I got from ...
1
vote
1answer
152 views

How to rename a file in the 14 hive - edited-

I need to rename the user.aspx file in the 14 hive layouts directory in a feature event receiver. Is this possible ...if so...how? OK - Bad idea....This is what i want to do: I have a custom ...
1
vote
2answers
299 views

Visual Studio 2010 Workflows not associating with list

Probably a silly question: I have a vs2010 project with workflows in a site scoped feature. When i deploy through visual studio the workflows are associated with lists. However when i deploy ...
4
votes
4answers
956 views

Web Template - Receivers Not Firing

I have a custom web template used to provision site collections that activates features with onet.xml and is deployed as a farm solution. I've tried both feature receivers and event receivers (on ...
5
votes
1answer
136 views

How to handle web references becoming stale in a web feature activation

We have a number of web-scoped features all stapled to a site definition, so they are all activated in turn when a web is created from the definition. It seems the feature receivers all share the ...
1
vote
1answer
2k views

Delete page from the Site Pages library

Wondering if someone has the code to delete a page from the Site Pages library in a Feature Event Receiver on de-activation TIA
0
votes
1answer
168 views

Versioning and upgrading features with SharePoint 2010 [closed]

I've been experimenting with feature version-ing and upgrading in Sharepoint 2010 and found a bunch of blogs, documentations etc. but it is still not very clear to me. How does Sharepoint store the ...
1
vote
2answers
3k views

The breakpoint will not currently be hit - debuging feature receiver

I need to debug my feature receiver, so I set up few breakpoints, but when I hit F5 in VS2010, they are all missed, and it says that "The breakpoint will not currently be hit. No symbols have been ...
1
vote
3answers
2k views

Powershell Deployment - Enable-SPFeature Error

I get the following problem activating a feature in powershell: Enable-SPFeature : The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: ...
3
votes
2answers
249 views

Feature Activation Logic (Prevent Activation)

I have three site collection features used to set branding throughout the site collection. I want to prevent the accidental activation of one of the features if one of the three is already activated; ...
2
votes
2answers
618 views

Why do I get a security validation invalid error updating a field from a feature receiver?

Trying to change the title field of a document library to be required..doesn't want to work. SPList docLib = web.Lists["Process Aids"]; SPField field = docLib.Fields["Title"]; field.Title = "Display ...
1
vote
1answer
103 views

Disable Web-scoped features on Web deletion

I have a SPWeb ( http://example.com/site ), created used a custom web template, with several features activated on its scope. When I delete the SPWeb it would be desirable that all the features ...
1
vote
2answers
124 views

Backup a file while custom feature activated?

We have a custom application page "custom.aspx" on the Layout folder, would like to rename the original file "custom.aspx" to "custom_bak.aspx" before the updated/modified custom application page ...
0
votes
1answer
659 views

Cannot set the associated group from a feature receiver

In a feature receiver, I want to create group and set the associated owner group of the Web. This feature is activated automatically from a custom site template (I think this the root of the problem). ...
7
votes
3answers
3k views

How do you “stop” activating a feature within the feature receiver?

I have a feature receiver with some long running code, hence I use SPLongOperation and delegate for better visual appearance. Basically my feature receiver looks like so: public override void ...
1
vote
1answer
2k views

Deleting Site Columns and Content Types Programmatically

I have a feature that adds two site columns to a content type on activation. On deactivation it's supposed to delete them, but I'm getting the following error: "Site columns which are included in ...
5
votes
2answers
878 views

Can't deploy Admin Approved Form Template using XSNFeatureReceiver in SharePoint 2010

I am trying to deploy an Administrator Approved InfoPath form template to SharePoint 2010 as a feature. I've done this lots of times in 2007 and never had an issue - but this will not play ball. I ...
2
votes
4answers
3k views

SP2010 Reset all subsites to inherit masterpage using c#

I'm creating a site feature reciever which sets a custom master page on the root web. I would also like the master page set on the root to be inherit to all the subsites. What is the most elegant way ...
2
votes
3answers
1k views

SPWebConfigModification class will not update Central Admin application's web.config file

Using SharePoint 2010 I am trying to use the SPWebConfigModification class to make some basic changes to web.config files on applications in the farm, including the Central Administration web.config ...
2
votes
1answer
392 views

Deploying webparts to default.aspx with a SiteDefinition feature dependency

I tried deploying a Site Definition with a custom default.aspx page. Within the <WebFeatures> node of the Site Definition's Onet.xml I tried to reference a Feature which would get a web part ...