Let's SharePoint

March 28, 2019 / Last updated : March 28, 2019 Sethu SharePoint Online

How to enable external sharing in Modern Hub site using Powershell?

Hello SharePointers, Below are the power shell scripts to enable external sharing in Modern Hub site param ( [Parameter(Mandatory=$true)] [string]$HubSiteUrl, [Parameter(Mandatory=$true)][ValidateSet(“Disabled”,”ExistingExternalUserSharingOnly”,”ExternalUserSharingOnly”,”ExternalUserAndGuestSharing”)] [String]$ExternalSharing ) $HubId = (Get-SPOHubSite -ErrorAction SilentlyContinue | Where {$_.SiteUrl -eq $HubSiteURL}).Id.Guid if ($HubId -eq $null) { Throw “Not a Hub site ” } $sites = Get-SPOSite -Limit All foreach ($site in $Sites) { […]

March 21, 2019 / Last updated : March 21, 2019 Sethu PowerShell

How to get result sources in SharePoint 2013/2016/2019 using Powershell?

Below are the powershell commands get result sources in SharePoint 2013/2016/2019 using Powershell. Add-PSSnapin Microsoft.SharePoint.PowerShell $ssa = Get-SPEnterpriseSearchServiceApplication $fedman = New-Object Microsoft.Office.Server.Search.Administration.Query.FederationManager($ssa) $searchOwner = Get-SPEnterpriseSearchOwner -Level Ssa $filter = New-Object Microsoft.Office.Server.Search.Administration.SearchObjectFilter($searchOwner) $filter.IncludeHigherLevel = $true $fedman.ListSources($filter,$true) | Select Name, Description, Active, Owner Happy SharePointing 🙂

March 16, 2019 / Last updated : March 16, 2019 Sethu Client Side Object Model

How to delete SharePoint list items before specific date in SharePoint online using Powershell?

Hello SharePointers, Below are the Pnp Powershell script to delete SharePoint list items before specific date in SharePoint online using Powershell. Connect-PnPOnline -Url <yourtenant>.sharepoint.com $listName = “EMployee” $items = Get-PnPListItem -List $listName -Fields “Title”,”Created”,”ID”,”GUID” // 30 days is the cut off period $days = (Get-Date).AddDays(-30) foreach($item in $items) { $created = $item[“Created”] Write-Host “Item created […]

March 6, 2019 / Last updated : March 6, 2019 Sethu Customization

How to get all site owners in SharePoint Online using Powershell?

Hello SharePointers. Below are the powershell script to get all the site owners of all the SharePoint sites. foreach($site in $sites) { $siteURL = $site.Url $siteOwner = $site.Owner Write-Host $siteURL -ForegroundColor Blue Write-Host $siteOwner -ForegroundColor Blue $siteAdmins = Get-SPOUser -Site $siteURL -Limit All | select LoginName,IsSiteAdmin | ? { $_.ISSiteAdmin } $siteUsers = “” foreach($siteAdmin […]

February 28, 2019 / Last updated : February 28, 2019 Sethu SharePoint 2010

How to create modern page in classic SharePoint site in Office 365/SharePoint Online?

To enable Modern pages in a classic sharepoint site, you need to activate the feature called “Site pages” at the site level. Here are the steps given below Navigate to your SharePoint site.Go to site settings, using Gear menu. On site settings page, select Manage site features from site action sectionActivate Site Page feature by […]

February 22, 2019 / Last updated : February 22, 2019 Sethu Client Side Object Model

How to convert classic page to modern page in SharePoint Online/Office 365 using Powershell ?

Hello Sharepointers, Below are the powershell script to convert classic page to modern page in SharePoint Online/Office 365. $pages = Get-PnPListItem -List sitepages # Loop through over the pages foreach($page in $pages) { if ($page.FieldValues[“FileLeafRef”].StartsWith((“classicpage”))) { # No need to convert modern pages if ($page.FieldValues[“ClientSideApplicationId”] -eq “b6917cb1-93a0-4b97-a84d-7cf49975d4ec” ) { Write-Host ‘Page $page.FieldValues[“FileLeafRef”] is modern,already’ } […]

February 20, 2019 / Last updated : February 20, 2019 Sethu Client Object Model

How to report SharePoint list item versions in Office 365/SharePoint online?

Hello SharePointers, Below are Powershell script to get all the version history of all list items in SharePoint online/Office 365. $List = $Ctx.Web.Lists.GetByTitle($ListName) $Ctx.Load($List) $Ctx.ExecuteQuery() $Query = [Microsoft.SharePoint.Client.CamlQuery]::CreateAllItemsQuery() $ListItems = $List.GetItems($Query) $Ctx.Load($ListItems) $Ctx.ExecuteQuery() $VersionHistory = @() Foreach ($Item in $ListItems) { write-host “Processing Item:” $item.id -f Yellow #Get all versions of the list item $Versions […]

February 16, 2019 / Last updated : February 16, 2019 Sethu PowerShell

How to export all the webpart in a sharepoint online page using Powershell?

Below are the power shell script to export all the web part in a SharePoint Page . foreach($item in $items) { $file = $context.Web.GetFileByServerRelativeUrl($Item[“FileRef”]) if($Item[“FileRef”] -eq “/sites/testwebpartpage.aspx”){ $wpManager = $file.GetLimitedWebPartManager([Microsoft.SharePoint.Client.WebParts.PersonalizationScope]::Shared) $context.Load($file) $webparts = $wpManager.Webparts $context.Load($webparts) $context.ExecuteQuery() $ pelement = $XMLFile.CreateElement(“Page”) $ pelement .SetAttribute(“id”, $Item[“ID”]) $ pelement .InnerText = $Item[“FileRef”] $ pelement .AppendChild($PageElement) | Out-Null foreach($webpart […]

February 16, 2019 / Last updated : February 16, 2019 Sethu Client Side Object Model

How to hide hours in SharePoint people picker in SharePoint online ,2010/2013/2016?

Hello SharePointers, Below are the powershell script to hide hours in People picker control in Sharepoint online/2010/2013/2016/2019. <script type=”text/javascript”> $(document).ready(function() { $(“select[id^=’People picker ID’]”).change(function() { $(this).find(“option[value=’4′]”).remove(); }); }); </script> Happy SharePointing 🙂

February 14, 2019 / Last updated : February 14, 2019 Sethu Office 365

Access Denied while moving navigation in Teams site in SharePoint online

Hello SharePointers, In case if you get access denied while working on the navigaton items in modern team site if publishing feature is activated. This is a knownn behaviour from Microsoft. You need to run the following SharePoint online script below to enable ” add or Deny or customize page property for this new team […]

Posts navigation

  • «
  • Page 1
  • Page 2
  • Page 3
  • …
  • Page 27
  • »

Recent Posts

  • How to insert table in Modern Pages using PnP Powershell in Office 365/Sharepoint Online?
  • How to set up Access Requests in SharePoint online using Powershell?
  • How to change the default SharePoint suite logo in SharePoint 2013/2016/2019?
  • How to add metadata to Document libraries in SharePoint online using powershell.
  • How to get Sharepoint site details using Powershell in Office 365?

Recent Comments

  • pradeep on How to show List items in SharePoint 2013 Using REST API and Content Editor Web Part

Archives

  • June 2019
  • May 2019
  • April 2019
  • March 2019
  • February 2019
  • January 2019
  • December 2018
  • November 2018
  • October 2018
  • September 2018
  • August 2018
  • July 2018
  • May 2018
  • April 2018
  • March 2018
  • February 2018
  • January 2018
  • December 2017
  • November 2017
  • October 2017
  • June 2017
  • May 2017
  • April 2017
  • March 2017
  • February 2017
  • January 2017
  • November 2016
  • October 2016
  • September 2016
  • August 2016
  • July 2016
  • June 2016
  • January 2016
  • November 2015
  • October 2015
  • September 2015
  • August 2015
  • July 2015
  • May 2015
  • April 2015
  • March 2015

SharePoint 2013

  • Anonymous access
  • Client Object Model
  • Client Side Object Model
  • Customization
  • Customization
  • Designer Workflows
  • Errors & Resolutions
  • Features
  • Google Analytics
  • InfoPath
  • Item Scheduling
  • JSOM
  • Nintex worflows
  • Office 365
  • Office 365 Groups
  • PnP JS Library
  • PowerShell
  • Powershell Online
  • REST API
  • REST API's
  • Server Side Object Model
  • SharePoint 2010
  • SharePoint 2010 Search
  • SharePoint 2013
  • SharePoint 2013 Search
  • SharePoint 2013 Workflows
  • SharePoint 2016
  • SharePoint 2019
  • SharePoint Designer
  • SharePoint Framework
  • SharePoint Online
  • SharePoint Pnp
  • SharePoint Usage Analytics
  • Unique values
  • User Profile Services
  • Windows Powershell
  • Workflow Manager

Find us on Facebook

Find us on Facebook

Follow me on Twitter

My Tweets

Copyright © Let's SharePoint All Rights Reserved.

Powered by WordPress & Lightning Theme by Vektor,Inc. technology.