Update-SPOListItem not Found

Category: azure automation

Question

Nivi Kolatte on Mon, 13 Aug 2018 07:42:28


I have configured user provisioning on azure automation by following the blog :

https://365lab.net/2016/01/09/create-ad-users-with-help-from-azure-automation-and-sharepoint-online/#comments

My webhooks are set to run on the Hybrid worker.

On execution I always get the below error:

Update-SPOListItem : The term 'Update-SPOListItem' is not recognized as the name of a cmdlet, function, script file, or
operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try
again.
At line:157 char:9
+         Update-SPOListItem -SPOConnection $SPConnection -ListItemID $ ...
+         ~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Update-SPOListItem:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

Update : Issue resolved 

The module imported to the azure automation didn't contain the Update-SPOList command.

After repacking the proper module and uploading it the error disappeared. 

Replies

CHEEKATLAPRADEEP-MSFT on Tue, 14 Aug 2018 04:13:37


It looks, you don't have installed the ASP.NET framework 4.0 or 4.5 on your client machine from where you trying to connect the SPOnline. Install it or register the .NET framework using aspnet_regiis tool.

You need to download the latest SPO online SDK from here

OR

Try to update SharepointOnline module.

Automation Account => Shared Resources => Modules => SharepointOnline module update

-----------------------------------------------------------------------------------------------

If this answer was helpful, click “Mark as Answer” or “Up-Vote”. To provide additional feedback on your forum experience, click here

Nivi Kolatte on Tue, 14 Aug 2018 05:34:57


I have asp.net framework running and the latest SDK on the hybrid worker.

The SharePoint module I imported is https://www.powershellgallery.com/packages/SharePointSDK/2.1.6 . It is updated


Nivi Kolatte on Wed, 15 Aug 2018 04:12:50


Update : Issue resolved 

The module imported to the azure automation didn't contain the Update-SPOList command.

After repacking the proper module and uploading it the error disappeared. 


CHEEKATLAPRADEEP-MSFT on Wed, 15 Aug 2018 06:44:12


Thank you for sharing your solution and experience here. It will be greatly beneficial for other community members who have similar questions.