Skip to main content

Change SharePoint site regional settings or culture info

Here is a quick script to change the regional settings for your sharepoint site.

function ChangeSiteCultureInfo() {
    [CmdletBinding()]
     Param(
      [Parameter(Mandatory=$True,
  ValueFromPipeline=$True)]
       [string]$spSiteUrl,
       [ValidateSet("en-AU","en")]
       [string]$culture = "en-AU"
       )
       BEGIN {}
    PROCESS
       {
         Write-Host "Processing site $spSiteUrl"
         $spsite  = Get-SPSite -Identity $spSiteUrl
         $rootWeb = $spsite.RootWeb 
         $cultureInfo = [System.Globalization.CultureInfo]::GetCultureInfo($culture)
         Write-Host "Curent local setting is $($rootWeb.Locale) "
         $rootWeb.Locale = $culture 
         $rootWeb.Update() 
         $rootWeb.Dispose() 
         $spsite.Dispose() 
         Write-Host "Finished Updating the locale of $spSiteUrl to $cultureInfo"
       }
       END {}
       
}
Usage:
 url_here | ChangeSiteCultureInfo

Comments

Popular posts from this blog

SharePoint 2013 workflow : The server was unable to process the request

Here, I received another SharePoint 2013 workflow error. This time the workflow was not able to send emails and the following error was being shown Retrying last request. Next attempt scheduled in less than one minute. Details of last request: HTTP Unauthorized to http://sitename/_vti_bin/client.svc/web/lists/getbyid(guid'guid') Correlation Id: id Instance Id: id Fortunately I came across this post which gave me the answer http://sharepoint.stackexchange.com/questions/89101/failed-to-retrieve-the-com-class-factory-for-component-with-clsid-sp-sprequest Solution 1: In InetMgr, go to advanced settings for Security Token Service Application Pool and change "Load User Profile" to true. Recycle application pool. Reason 2 and Solution 2 : There could be another reason for this error. The workflow authentication can fail if the user executing the workflow (this will be the user initiating the workflow) is given permission through active directory group and the co...

OWA not working after security update

Office web apps for SharePoint 2013 not working after security updates / server patching. After installation of the following security patches, OWA stopped working there by causing issues with SharePoint 2013. Details of ULS logs are provided below. FarmStateReplicator.exe (0x0CD8) Office Web Apps Farm State Error when trying to connect to Farm State Manager service: System.ServiceModel.EndpointNotFoundException: There was no endpoint listening at http:// /farmstatemanager/FarmStateManager.svc that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress) at System.Net.ServicePoint.ConnectSocketInternal...

Your me, my me and the other me. A guide to be at peace with personal growth

This article is not a direct address to a problem statement, but a journey with me to certain philosophies that I have entertained in my quest for personal growth. There is a short and effective way to look at personal growth which I will come to in this article, one that I believe will help you to be more closer to peace with the practice of personal development.  I am thankful to many people in my life, for instilling in me a desire for personal growth in my life.  Both my parents have always been open to learning and cared to share some of their struggles with difficult choices and dilemmas associated with scenarios. A few school teachers stood out in vocalising their own personal learnings and set an example by embracing the incompleteness in spite of not being required to do so. I was fortunate to have attended a school that celebrated learning and instilled pride, largely thanks to the unconventional principal that held office there. The themes you can notice in these ex...