Tag Info

Hot answers tagged

21

For Features SharePoint Features can be scoped to the Farm, Web Application, Site Collection, and Web Site level depending on the purpose of the feature. The Feature scope is determined by the setting of the Scope attribute in the Feature element defined in the feature.xml file. A sample Feature element tag is given below: <Feature ...


17

There are quite a few things to consider in organizing your structure, or else maintanance or understanding the code becomes a nightmare (even if you revisit after a few years). A similar question was asked in an earlier best practices post. Some rules I follow are: Keep all projects in one folder ("Projects"), keep solutions in another folder ...


17

With Visual Studio 2010 it is easy to build a WSP. Additional tools are not required, especially for a project as you described. The basic steps are: Create a new SharePoint 2010 project using the Empty SharePoint Project template. For each of your items that you want to add, right click on your project in Solution Explorer and choose Add New Item. Choose ...


15

It's called "Publish" now. Functionality is basically the same.


12

If you read Vesa Juvonens super-article about SharePoint 2010 WebTemplates, http://blogs.msdn.com/b/vesku/archive/2010/10/14/sharepoint-2010-and-web-templates.aspx, you will see how he organizes and names features and SPI's. It's a very good approach and it mmakes it very easy to locate SPI's and features in the (not so user-friendly when you have tons of ...


10

Ok, for the wsp part follow laurie, or if your lazy add wspbuilder to visual studios to build the wsp for you. now to add the masterpage and css: create an empty project add module as you can see above, remove the sample.txt, right click styles and add your masterpage and add another module for css :) for the css, click on the elements.xml and add ...


9

This can occur when an installed feature is renamed. Either reverse the rename or uninstall the feature. PowerShell's Uninstall-SPFeature <Guid> -force will not work. You should use stsadm -o uninstallfeature -id <Guid> -force instead.


9

Not sure why it wasn't working through the Central Admin but I ended up doing it through the Management Console using the following commands: Uninstall-SPSolution -Identity mySolution.wsp -allwebapplications Remove-SPSolution -identity mySolution.wsp -force Hope this helps someone.


9

If the WSP has any assemblies in it - no. The assemblies developed for SharePoint 2010 will be referencing the SharePoint 2010 core assemblies, and will fail when trying to load them in SharePoint 2007. If the WSP only has XML in it, and no server side code in assemblies, it should deploy fine, given it has no Feature code that's new in 2010 (such as ...


8

Project Structure - I'm still experimenting with different styles, though it seems to be the norm to split off artefacts (such as c# WebParts) atomically, and use project references to include a "release version" of that project into a SharePoint Project designed solely for Packaging. This prevents you from building half-finished and broken code and ...


8

I have to disagree with James. The SPContentType in SharePoint 2010 has a new constructor that lets you specify the content type id. The addition of the Inherits attribute of the ContentType element makes the behavior of content types described in CAML inconsistent. Finally, the Feature upgrade mechanism is great if you are adding fields but it doesn't ...


7

When you have common/shared components, like the helper DLL you talk about, that get used acros multiple solutions within you ogansisation. My recommendation is to package these up as a 'framework solution' that is deployed to the servers indendently of the 'feature based solutions'. This way you 'feature solutions' are developed in the knowledge that ...


7

In the Timer Job project, open the package designer. Click Advanced (bottome of the designer) Click Add, and choose Add Assembly from Project Output. Select Project A Repeat selecting the other project. All your assemblies will be in the Timer Job solution, and is the only one you need to deploy to SharePoint.


7

I think that any .Net guidance that you can find is a really good start, since it's still a .Net project. You could look at the Developing Application for SharePoint 2010 from the Microsoft Patterns & Practices, which is more specific.


7

To deploy a .wsp farm solution you need to be a local administrator on the server: Adding a solution package Before you can deploy a solution package, you must add it to the solution database of a SharePoint Server farm. Important: You must be a member of the Administrators group on any computer on which you run Windows PowerShell. To ...


7

We can either manually do it through central admin or by using powershell commands. I would prefer doing this through powershell To uninstall and remove Farm solutions use the Uninstall-SPSolution and Remove-SPSolution cmdlets (Use -WebApplication attribute if the solution has webapplication-scoped resources): Uninstall-SPSolution –Identity ...


6

the article you reference at the end of your question really answers it: custom web services should be placed in _vti_bin. i usually start by adding them to _LAYOUTS but thats only to be able to define my discovery files etc (as described in the MSDN specification you mention). _vti_bin is a virtual directory mapped to the 12/ISAPI folder, so you can ...


6

If the solution has no web application resources it is considered a global solution and does not actually need to target an web applications. Remove the -AllWebApplicaitons and this global solution will be deployed globally to the farm and will be available to all web applicaitons.


6

As the documentation states, when you add new artifacts to a solution you need to reinstall it. Really nothing new here, except for support for solution dependencies (and this is really only half implemented, since you can delete solutions that other solutions depend upon without getting any warning) Feature upgrade is an entirely different matter. No ...


6

By doing that you are deploying your solutions to the farm and therefor you can find it if you go to Central Administration System Settings Farm Management > Farm Solutions If you want to deploy it to sandbox solution using powershell then your solution will need to be sandbox solution compatible and you can use the following command ...


6

The Visual Studio 'Deploy' command actually invokes all the deployment steps in the current project deployment configuration. If you go and check by default it performs many seperate tasks under the coverall of 'Deploy'. That's under the SharePoint tab of the project properties window. The 'Deploy' function also does conflict resolution such as deleting the ...


6

The most highly praised, probably the most widely used, and personally my favourite SharePoint dev tool ever created is possibly your best solution to this. WSPBuilder: http://wspbuilder.codeplex.com/ You'd need to reorganise your folder structure of the WSP into what WSPbuilder expects, but this is probably your fastest way to do this. We have recreated ...


6

There is no good way to debug in SharePoint online. You basically have two options Remove/add pieces of declarative content one at a time to rule out any failing parts If you have code that do the provisioning, use a list to log all exceptions.


6

Elements by Scope helps you understand what elements are allowed for each scope. That also means that solutions can be developed and SharePoint architecture allows them to be deployed at any of the scope documented. Most solutions use FEATURES that are targeted at web or site collection level and when an element is allowed at both web and site level, it ...


6

We've found it's much easier to just add a webconfig.something.xml file to the Config folder. So for your one entry you can create an xml file with these contents: <?xml version="1.0" encoding="utf-8" ?> <actions> <remove ...


5

The following link describes sharepoint 2010 project structure (VS project structure) http://bitofthought.blogspot.in/2012/05/visual-studio-sharepoint-solution.html


5

I think you still need to activate the feature that deploys your webpart. As far as I can see you have installed the solution and thereby installed the feature but not activated the feature that contains your webpart. So add the line enable-spfeature -identity foobarwebpartfeature -url yourwebsite in your script to ensure that the feature is activated.


5

I used the following techniques a few times (with SP2007 and SP2010) : Library solution Create a SharePoint project "YourLibrary", that contains all the shared code. Package the code in a separate WSP The most important part : create a Farm Feature, empty, auto-activated at the install The 3rd point is important, because your projects that depends on ...


5

It is by-design that retract doesn't remove actual data. There is no event handler either that you could use to remove content after solution has been retracted. :( I guess you would need to create custom functionality that will clear old content and run it after retracting solution. Would it be possible to use site collections for this, and then just ...



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