Sunday, September 18, 2011

Migrating SharePoint 2007 Site/List Templates(.stp) into SharePoint 2010

Unfortunately, SharePoint 2007 site templates(.stp) can't be used as in SharePoint 2010. Hmm... Then what to do with the custom SharePoint 2007 Site templates? Can't I use them in SharePoint 2010? well, You can,  Here is the work around to Migrating MOSS 2007 Site, List Templates(.stp) to SharePoint 2010:
  1. Create a site in SharePoint 2007 using the custom .stp template.
  2. Migrate that site to SharePoint 2010 by either In-Place or Database attach method (backup the database for that site from SQL Server for SharePoint 2007 and restore it on SharePoint 2010's SQL Server, then atach the DB(stsadm -o addcontentdb) to SharePoint 2010)
  3. After you do that just Open up the site and fix any issues (like file system references).
  4. Once upgraded to SharePoint 2010, follow these steps:
  5.   Click on Site Actions >> Site Settings.
  •   On the Site Settings page click "Save site as Template", then enter a file name and Template name and click OK.
  •    Now, The site template is saved as a WSP file to the Solutions Gallery for that site collection. This solution can then be re-used as a Site Template.
Migrating MOSS 2007 Site,List Templates(.stp) to SharePoint 2010
Open the .wsp solution in Visual studio 2010, change the Scope to “Farm” and re-deploy, if you want this site template to be available at the farm level.

Important: When saving site as a template enable "Include Content" check box! otherwise you may end up in Error: Exception from HRESULT: 0x81070905" when creating sites from the particular template.

Migrating List Templates from MOSS 2007 to SharePoint 2010
Likewise, List templates created in MOSS 2007 can't be used in SharePoint 2010. You will get this error when you try to create a list based on MOSS 2007's List template:

 Error: Microsoft SharePoint Foundation version 3 templates are not supported in this version of the product!
Migrating List Templates from MOSS 2007 to SharePoint 2010

Fortunately, There is a work around. We can use the same method as above. Or if its just a list template, we can use the below trick:
  1. Download the .STP file from the site, and Rename .STP to .CAB
  2. Extract the manifest.xml
  3. In "ProductVersion" element, Change its value to from "3" to "4"
  4. Repackage the manifest.xml into a .CAB. makecab.exe c:\manifest.xml c:\template.cab
  5. Rename the .cab file from .CAB to .STP and upload it into the List templates (_catalogs/lt)
Here is a scripted way: http://www.heyweb.net/2011/06/converting-sharepoint-2007-document-library-templates-for-sharepoint-2010/



    You might also like:
    SharePoint Usage Reports
    Usage reports, collaboration and audit for SharePoint.
    Document SharePoint Farm
    Automatically generate SharePoint documentation.
    *Sponsored


    Check out these SharePoint products:

    2 comments :

    1. Very useful tip on dealing with the Exception from HRESULT: 0x81070905. Thanks!

      ReplyDelete
    2. I have migrated site to 2010. It works fine.
      Then I have created site template from it, which is .WSp file.
      Now while creating site from that template I am getting an error of
      "Unable to load assembly group. The user assembly group provider was unable to provide any user assembly for the specified assembly group.". What can I do with this ?

      ReplyDelete

    Please Login and comment to get your questions answered!

    You might also like:

    Related Posts Plugin for WordPress, Blogger...