It is possible to create site collections programmatically. The Site Collection creation can be accomplished in the following ways
1) Using SharePoint Object Model
2) Using Central Admin’s Admin Web Service
Creation Site Collection using SharePoint Object Model
See the following code snippet, which uses SharePoint Object Model to create site collection.
1) Using SharePoint Object Model
2) Using Central Admin’s Admin Web Service
Creation Site Collection using SharePoint Object Model
See the following code snippet, which uses SharePoint Object Model to create site collection.
Creating Site Collection using Admin Web Service
The Admin Web Service of Central Admin has the following web methods
The Admin Web Service of Central Admin has the following web methods
The following code snippet uses “CreateSite” web method to create a site collection.
After the successful creation of site collection, this web method returns the URL of the newly created site.
No comments:
Post a Comment