Questions tagged [pnp-powershell]

PowerShell commands that allows you to perform complex provisioning and artifact management actions towards SharePoint. The commands use CSOM and can work against both SharePoint Online as SharePoint On-Premises.

Filter by
Sorted by
Tagged with
5
votes
3answers
12k views

Retrieve Permissions at folder and file level in Powershell

We're on Sharepoint Online. After migration, would like to validate that all permissions are applied accordingly. Have following code : Connect-PnPOnline -Url $siteUrl $context = Get-PnPContext $...
0
votes
0answers
39 views

How to access the Security trim for SharePoint Online using Powershell

I have been trying to access the securitytrim (_layouts/15/SiteNavigationSettings.aspx)context under the sitenavigationsettings page in sharepoint online. I can do them easily for the on premise ...
1
vote
0answers
470 views

Not able to Load Managed Metadata Context

I am trying to create Term with PowerShell in SharePoint Online to do so I have written below code but on [Microsoft.SharePoint.Client.Taxonomy.TaxonomySession]::GetTaxonomySession($spContext) ...
2
votes
1answer
1k views

PnP Poweshell: Get-PnPListItem Restrict to a Specific View

I'm using Get-PnpList and Get-PnpListItem to retrieve all items in a specific list, but I would like to restrict the items to only those in a specific view? Is this possible? Maybe with a CAML query, ...
1
vote
1answer
269 views

Insert LookUp column in list using Sharepoint PNP PowerShell

I've this code bellow OfertaParticulares Connect-PnPOnline -Url https://test.sharepoint.com/sites/test/Negocio/OfertaParticulares -Credentials (Get-Credential) $listName="Páginas" $fieldName="...
1
vote
1answer
181 views

How to copy the folder structure and permissions with in the same library

I have a document libray with structure like given below: FolderA->Subfolder1->item1 Subfolder2-->item2 They have folder level permissions . now ...
0
votes
1answer
939 views

Fetch Username from Lookup-Column using Powershell-PNP

I am trying to retrieve the actual username from a lookup column, the closest I got is $test=(Get-PnPListItem -List $list -Fields Owner -Id 1).FieldValues This of course returns the value as ...
0
votes
3answers
86 views

How to change versions of PnP PowerShell

I have two versions of PnP PowerShell loaded on my machine: SharePointPnPPowerShell2013 3.11.1907.0 SharePointPnPPowerShellOnline 3.1.1809.0 I'm having issues running code against SharePoint 2013. ...
0
votes
1answer
106 views

Deleting all files in document library PNP SPO

Hi I'm deleting all files and folders from a document library with the following code but errors in the console. However the files do get deleted. Any ideas as don't want to see the errors? $items =...
0
votes
1answer
637 views

How create publishing page via CSOM or Powershell (SharePoint Online)

I would like to automate creation of a subsite and of a publishing site. Is it possible to create a publishing site and also dynamically add webparts to it e.g create also a document library on the ...
0
votes
1answer
828 views

Picture library thumbnail url

Is there any way in powershellscript to get the thumbnail url from Picture library.? Actually i wan to use in custom search display template to get the thumbnail image.