Skip to content

Set-PnPListItem - Object reference not set to an instance of an object #1037

@Yermek-Zhandauov

Description

@Yermek-Zhandauov

SharePoint Online
PSVersion 7.1.0
PnP.PowerShell - 1.7.4

error

When trying to update Managed Metadata field Set-PnPListItem -List $ListName -Identity $id -Values @{"Field Name" = $TermGUID} -Connection $PnPConnection -UpdateType SystemUpdate -Batch $batch I am getting error with the message:

Message : Object reference not set to an instance of an object.
Stacktrace : at PnP.PowerShell.Commands.Utilities.ListItemHelper.GetFieldValues(IList
list, IListItem existingItem, Hashtable valuesToSet, ClientContext
clientContext, PnPBatch batch)
at PnP.PowerShell.Commands.Lists.SetListItem.ExecuteCmdlet()
at PnP.PowerShell.Commands.PnPSharePointCmdlet.ProcessRecord()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions