Add the “Create a Site” action to a SharePoint 2010 Designer Workflow
Configuration
URL: The url of the web site. You could either use an relative url to create the site direct under the current site or an absolute url to create the site under any site. The workflow initiator needs appropriate permissions. Or you can use an impersonation step to run the action under the permissions of the workflow author.
Title: Title of the site
Description: Description of the site
Template: Template name of the new site. Default is Team Site (STS#0).
You can get a list of all farm templates with the PowerShell command “Get-SPWebTemplates”.
To get a list of templates from a specific site’s template catalog use the following PowerShell command:
Get-SPWeb http://contoso/sites/spd | %{$_.GetAvailableWebTemplates($_.Language)}
Use the name of the template e.g. WIKI#0
Language Code: The language code for the new site e.g. 1033 for English or 1031 for German. 0 means inherit the language from the parent site.
Inherit Permission: Inherit permissions from the parent site.
Inherit Top Navigation: Use the same top navigation as the parent site.
Output: Returns the absolute url of the new site
8 comments:
Just what i needed, tnx alot. The entire solution is awesome. Tried to make my own "Create Site from template" workflow in VS 2010, but im not a decent programmer and I failed hehe. You are using a Activity Library? Sry if its a stupid qusetion, but im very intersting learning how its done, still on uni and I have a project about SP2010.
Anders, sorry I'm a little bit late. Active Library? No, just take a look in the my source code that is available on CodePlex.
Bye, Christian
Hi ,
I have been looking for this to complete my task form last couple of days .Then Yesterday i did in visual studio.This i install for all web-applications in sharepoint and it's awesome.Request you to mail me to mdsiddiqali@hotmail.com .I want to know more about this kind of wsp files .Hope you respond to me.
Thanks,
Quality Communication Provides
Quality Work.
siddiq-sharepoint2010.blogspot.com
Mohammad Siddiqali.
Thanks for the feature... this is exactly what I was looking for. I'm having an issue though. I had no problems installing the feature and activating it. The issue I'm having is after creating a workflow that uses the "create site" action, I receive no error, the workflow says it completed but the site is never created. Where are the errors logged so I can see what is going on? Thanks!
@michele: Wasn't able to repdoduce the issue. You should find the error in the error variable of the action and in the SharePoint ULS Log.
Does this cater for using ports? My site didn't want to create so I checked the error output and it said : is an illegal character.
Is there a workaround for this?
I am using a custom template and this is what appears in the Name field when listing the templates:
{56685AF0-0AAB-461B-9204-89F1AC045661}#IT_PMM_Template.
What exactly should be placed in the template field. I tried the whole thing and that fails. Greg
This is great. I was doing this as an application page before seeing your example. Just wondering, after the workflow completes, how would I have the workflow navigate to the new provisioned URL?
Thanks
Post a Comment