Home
About Us
Contact Us
Advertise
Facebook
Twitter
RSS Feed
Printable version
Learn to use SharePoint Project Items
By Phil Jirsa
July 9, 2012 —
(Page 2 of 2)
SPI Configuration
SPIs provide us with good encapsulation of functional elements and give structure to our project. They also provide the ability to customize the deployment of our items.
Feature manifests are often deployed with properties defined in them that provide customization and reusability for the feature. SPIs have a Feature Properties collection associated with them that allows us to define feature properties specific to our item. Those properties are brought along and added to the feature manifest of any feature where we choose to include in our SPI.
Figure 3
Solution manifests are responsible for declaring where artifacts are deployed in the SharePoint farm. Each item within our SPI has a property called “Deployment Type” and “Deployment Location.” These can be used to tell our solution where we want our artifacts deployed. As an example, right-click on VisualWebPart1UserControl.ascx and choose properties. The Deployment Type is set to “TemplateFile” and the Location is “{SharePointRoot}\Template\CONTROLTEMPLATES\SharePointProject1\VisualWebPart1”. We could have just added a “CONTROLTEMPLATES” mapped folder to our project, but this provides a nice way to keep all of our related artifacts together for our SPI. The result is an entry in our solution manifest that looks like Figure 4.
Figure 4
To learn more about SPIs and to see a full listing, visit
msdn.microsoft.com/en-us/library/ee231554.aspx
.
Phil Jirsa is a SharePoint developer at SharePoint911, a Rackspace company.
Related Search Term(s):
SPIs
Pages
1
2
Share this link:
http://www.sptechweb.com/link/36785