views:

32

answers:

1

I need to be able to create a new site collection from one SharePoint 2010 farm to another. I.e. the user fills out the forms associated in SharePoint Farm 1 and creates a site collection with the specified info in SharePoint Farm 2.

I have considered the following alternatives:

  1. Using the Client Object Model (COM), but the highest available object is SPSite, and I need a SPWebApplication object to create a new site collection.
  2. Using a built in SharePoint 2010 Web Service, but which one? Neither WebSvcAdmin, WebSvcSiteData, or WebSvcsites seems to be able to do this.
  3. Implement a custom web service, but what about authentication?
+1  A: 

You need to use SPWebApplicationBuilder class. But instead of SPFarm.Local use SPFarm.Open(SqlConnectionStringBuilder connectionString, string user, string password)

cement