If you perform any automated website or list/library creation in SharePoint, you would at one point or another need to define and add fields (SPField) via code using the AddFieldAsXml method of the SPFieldCollection class. This article focuses on a few “gotchas” you may encounter while working with this method.
Depending on the folders into which items are uploaded in SharePoint, you may want to set default column values so that instead of a global column default value, your default values become folder-specific. This article demonstrates how to do this using C# code on a SharePoint 2016 server. The code can be added to event receivers to keep child items updated when something changes somewhere.
PowerShell desired state configuration scripts often request user credentials which then need to be stored in some form in the output MOF files. Since you never want to save passwords as clear text, this article explains how you can keep passwords secure and encrypted inside your MOF files.
Access requests can be configured per site in SharePoint site settings. And there are quite a few PowerShell scripts out there to set the value of the email address that receives the notifications. However, what if you prefer to completely turn off the site access requests feature for all your websites in one shot, and then just display an access denied message when necessary? This article provides a PowerShell script for that purpose.
This article addresses an error associated with “ChannelOperationTimeout” when using Visual Studio to deploy SharePoint WSPs. The issue is generally associated with either very slow virtual machines, or very large SharePoint WSP package deployments.
I have been playing a lot with PowerShell desired state configuration (DSC) recently and so, I decided to write an introductory post on it. In this article, I explain at a high level what PowerShell DSC is all about. And then, I provide a simple example that demonstrates at a basic level how PowerShell desired state configuration works.