Using the SharePoint Object Model on a SharePoint 2007 environment and the remote object model to talk to a SharePoint 2010 environment would it theoretically be possible to migrate sites or content back and forth between these environments?

Essentially I have two environments of different versions (one 2007, one 2010) and I'm looking for a way I can write some code to move content between the two with ease.


Moving sites from SP 2007 to SP 2010 would require an upgrade of the content (content db). Plus both enviornments will need to be in sync before the migration can take place i.e. all the custom solutions will need to be deployed in SP 2010, all your custom site defs etc.

This article shows how you can attach a content db from sp2007 to sp2010. http://technet.microsoft.com/en-in/library/cc303436%28v=office.14%29.aspx

Using the above article you will be able to come up with a powershell script to automate.

If you were looking to maintain both enviornment and just move content between the two enviornments, take a look at content deployment but I am not sure if it will work with differnet enviornments.


Sharepoint 2007 (MOSS) and Sharepoint 2010 are two different environment and for console or other application can't access both these application url from a single box. If you run your program from MOSS environment, you can access the sites that are in SP 2010 and vice versa. So you have to take help of sharepoint web services. Take a look at Migrate documents from MOSS 2007 to SP 2010 programmatically.


There are several factors that needs to be considered before you are planning to move your site from 2007 to 2010 . Please check the below link explaining the step by step process of doing it. Link for Solution...The method shows the DB Attach method.

  • 2
    -1 The DB attach method is not a programmatic approach as requested by the asker. – Stu Pegg May 21 '13 at 7:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.