Create a new Link list with pre-populated list items as a feature based solution.
1. Lets create a SharePoint 2010 list instance feature with Visual Studio. Create a New Empty SharePoint Project, Give it a name, I've named it as Crescent.Portal.DashboardLinks
2. In the next dialog box, Select either Farm solution or Sandboxed solution whichever applicable to your requirements. I've selected "Deploy as a Farm Solution"
3. Right click the Project in visual studio solution explorer >> Add >> New Item >> List Instance to create new SharePoint 2010 list using visual studio
4. Enter the List Instance settings: Link List Name, List to Instantiate, URL. Click Finish.
5. Now our project will look like the below screen. Look at the "FeatureId" attribute. This is the Feature ID of the Link List feature. In case, If you want to create a List instance for your own List definition, You can use the Feature ID of the particular List. (You can just get into 14 Hive, Templates and pick the relevant feature folder's Feature.xml file to get the feature Id)
7. Our requirement is to Pre-populate the Dashboard Links list. So, Lets add the <Data> element with values to the Elements.xml as below:
SharePoint 2010 list instance elements.xml
<?xml version="1.0" encoding="utf-8"?> <Elements xmlns="http://schemas.microsoft.com/sharepoint/"> <ListInstance Title="Dashboard Links" OnQuickLaunch="TRUE" TemplateType="103" FeatureId="00bfea71-2062-426c-90bf-714c59600103" Url="Lists/DashboardLinks" Description=""> <Data> <Rows> <Row> <Field Name="URL">http://Crescent.SharePoint.com/sites/PMO/Dashboard, PMO Dashboard</Field> <Field Name="Comments">PMO Dashboard Link</Field> </Row> <Row> <Field Name="URL">http://Crescent.SharePoint.com/sites/functional/Dashboard, Functional Dashboard</Field> <Field Name="Comments">Functional Dashboard Link</Field> </Row> <Row> <Field Name="URL">http://Crescent.SharePoint.com/sites/operations/Dashboard, Operational Dashboard</Field> <Field Name="Comments">Operations Dashboard Link</Field> </Row> </Rows> </Data> </ListInstance> </Elements>
9. Verify the feature is activated by going to Site actions >> Site settings >> Manage Site features (Under Site actions tab)
You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.