New answers tagged

2

SOLVED: After lengthy research I was able to come up with a working solution. // Break Inheritance from Parent library newFolder.Item.BreakRoleInheritance(true); // Remove 'Visitor' group from permissions SPPrincipal principal = (SPPrincipal)webDst.SiteGroups["Visitor"]; ...


0

PowerShell is just a wrapper for the object model. You can create Web Template & create Sites and Site Collections from that Custom Web Template using method mentioned in below reference. Programmatically creating Sites and Site Collections from a Custom Web Template ---------------------EXAMPLE 1----------------------- Move-SPSite ...


0

This is an example from MSDN using SSOM. SPWebApplication webApp = new SPSite("http://MySiteCollection").WebApplication; SPSiteCollection siteCollections = webApp.Sites; SPSite newSiteCollection = siteCollections.Add("sites/Site_Name", "Site_Title", "Site_Description", 1033, "STS#0", "DOMAIN\\Owner", "Owner_Display_Name", "Owner_Email", ...



Top 50 recent answers are included