Created
February 27, 2019 20:11
-
-
Save itsthedoc/d1fe52b8ea4370212b3e681598287c19 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Import-Module SharePointPnPPowerShell2013 -DisableNameChecking | |
Connect-PnPOnline -Url "https://sharepoint/sites/mainsitepage" -CurrentCredentials # if logged into domain | |
$list = Get-PnPList -Identity "917d9483-d6c4-4f47-8f88-4beac30df4a1" ## Tip: Use Get-PnPlist with no identity to find your list ID | |
$context = Get-PnPContext | |
$web = $context.web | |
$context.Load($web) | |
$fields = $list.Fields | |
$context.Load($fields) | |
$query = New-Object Microsoft.SharePoint.Client.CamlQuery | |
$items = $list.GetItems($query) | |
$context.Load($items) | |
$context.ExecuteQuery() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment