SharePoint Designer being a very powerful tool can be used to perform many operations inside SharePoint Environment, creating Workflows, External Content Types, Master Pages & Page Layouts Branding are to name a few of them.
Since Microsoft already announced that there will be no new version of SharePoint Designer to be released for SharePoint 2016 and the existing SharePoint Designer would be fully functional with it so it even becomes more important to understand the governance around this excellent tool.
Being a tool with reputation to perform so many actions it is utmost important to work around proper governance plan per Web Application basis to control this little beast.
In this article we will be going to walk through the steps and PowerShell Scripts involved in configuring the SharePoint Designer settings.
Before we start configuring the settings for SPD lets’ see what will happen if these settings are not enabled on Web Application Level
Search for SharePoint Designer and Launch it
Now try opening any Site using SharePoint Designer and boom
Got an error: Access Denied!
This is due to the fact that SPD usage permission has been revoked already we would be looking an obvious SharePoint Error saying access denied even if the user has full access the Site itself. This is because of the fact that SharePoint manages permissions for SPD and Sites separately.
Now in order to enable permissions for SPD we can go along with the following steps-
- Launch Central Administration Site
- Click on “General Application Settings”
- Click on “Configure SharePoint Designer Settings” Link under SharePoint Designer Section
Select Web Application for which you want enable SharePoint Designer Settings
And in the screenshot below we can see there are four properties that need to be configured to get SPD up and running.
Since we are looking for automating SharePoint Configurations using PowerShell so we will configure it by PowerShell way only.
Since this article is about implementing automation for SharePoint configurations using PowerShell, so we will go along with PowerShell only.
- Get Web Application Object that you want to enabled with SPD usage
$webAppObj = Get-SPWebApplication -Identity http://sp-2016-dev
- Set AllowDesigner, AllowRevertFromTemplate, AllowMasterPageEditing, ShowURLStructure properties to “true” if you want all SPD features enabled for the Web Application
$webAppObj.AllowDesigner = $true
$webAppObj.AllowRevertFromTemplate = $true
$webAppObj.AllowMasterPageEditing = $true
$webAppObj.ShowURLStructure = $true
- After setting the required properties don’t forget to call Web Application Update Method to save the changes back to database.
- Launch SharePoint 2016 Management Shell
- Run the above commands
Once the commands get executed we can go back to “SharePoint Designer Settings” Page to verify the changes to the properties persist.
Now try connecting to the Site again
And since the permissions has been enabled to the Web Application for SPD Access you can be able to connect to the site with the Web Application as shown in the screen shots below-
That is all for this demo.
Hope you find it helpful.