pnp / PnP-PowerShell

SharePoint PnP PowerShell CmdLets
https://pnp.github.io/powershell
Other
989 stars 662 forks source link

[BUG]Issue in PowerShell 7, "Get-PnPProperty: Cannot bind parameter 'ClientObject'. Cannot convert the "Microsoft.SharePoint.Client.Folder" value of type "Deserialized.Microsoft.SharePoint.Client.Folder" to type "Microsoft.SharePoint.Client.ClientObject" #2854

Closed guptarajesh001 closed 4 years ago

guptarajesh001 commented 4 years ago

When we run the below command on Powershell 7, to fetch detail of folder in the sharepoint. Get-PnPProperty -ClientObject "david onedve/3200 in 400mb/Level 2" -Property Files, Folders , we are getting below error: Get-PnPProperty: Cannot bind parameter 'ClientObject'. Cannot convert the "Microsoft.SharePoint.Client.Folder" value of type "Deserialized.Microsoft.SharePoint.Client.Folder" to type "Microsoft.SharePoint.Client.ClientObject".

However, its run successfully on Powershell 5.1

erwinvanhunen commented 4 years ago

We currently do not support PowerShell 7. While some things -might- seem to work, the underlying .NET implementation behind PowerShell 7 is fundamentally different from PowerShell 5. We are working on releasing a version specifically for PowerShell 7, but until then you are required to use PowerShell 5.