Skip to content
This repository was archived by the owner on Jan 19, 2021. It is now read-only.
This repository was archived by the owner on Jan 19, 2021. It is now read-only.

Cannot bind parameter 'ClientObject'. Cannot convert the "Microsoft.SharePoint.Client.ListItem" value of type "Deserialized.Microsoft.SharePoint.Client.ListItem" to type "Microsoft.SharePoint.Client.ClientObject" #2883

@guptarajesh001

Description

@guptarajesh001

When we run the below script on the Powershell version 5.1 for fetching the file property.

workflow IterateWorkflow
{
Parallel {
Connect-PnPOnline -Url $SrcFolderURL -Credentials $creds -ErrorAction SilentlyContinue -WarningAction SilentlyContinue
$folderUrl = "/Documents/It's a level 3 folder for testing/Level 4/file-sample_100kB.doc"
$file = Get-PnPFile -Url $folderUrl -AsListItem
if ($file) {
Get-PnPProperty -ClientObject $file -Property HasUniqueRoleAssignments, RoleAssignments
}
else {
$file = Get-PnPFile -Url $folderUrl -AsListItem
Get-PnPProperty -ClientObject $file -Property HasUniqueRoleAssignments, RoleAssignments
}
}
}

We are getting Microsoft related issue, however, its running successfully with non workflow.

Cannot bind parameter 'ClientObject'. Cannot convert the "Microsoft.SharePoint.Client.ListItem" value of type "Deserialized.Microsoft.SharePoint.Client.ListItem" to type "Microsoft.SharePoint.Client.ClientObject"

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions