PnP issue on SPO DocumentSet
Hi
I am struggeling with an PnP issue on Documents Sets. I need to update the property values on the Document Set shared properties as well as properties in documents (with different content types) inside the Document Set
I tried somthing like this:
$docs = Get-PnPListItem -web $subsiteurl -List $TargetListID
foreach ($item in $docs){
$spfile = Set-PnPListItem -List $TargetListID -Identity $item.Id -Values @{"xx"="$xx"}
$spfile = Set-PnPListItem -List $TargetListID -Identity $item.Id -Values @{"yy"="$yy"}
etc
I do get the List/ibrary items including the Document Set folder, but it is NOT able to Set-PnPListItem values, I get no errors when running the powershell
I did this on SP2013 on-premise with no problem like this:
$weburl = $_['TargetSiteURL']
$web = Get-SPWeb -Identity $weburl
$list =$web.lists["TagetlistName"]
foreach($item in $list.folders)
{
$item["xx"]=$_['xx']
$item["yy"]=$_['yy']
etc
$item.update()
Please Post if you have a hint to a solution...
Anyone with input :-) ?? much appreciated
/ MBNielsen