Advertisement

Responsive Advertisement

Create a SharePoint List Online using PnP PowerShell O365

In this article, we will see how to SharePoint List Online using PnP PowerShell.
Before you begin utilizing PowerShell to oversee SharePoint Online, ensure that the SharePoint
Online Management Shell is installed.


You can install the SharePoint Online Management Shell by downloading and running the SharePoint
Online Management Shell.You only need to do this once for each computer from which you are running
SharePoint Online PowerShell commands.

Before connecting to the SharePoint site, we need to get Credentials by using the Get-Credential
cmdlet which creates a credential object for a specified username and password.

You can use the credential object in security operations. By default, an authentication dialog box
appears to prompt the user like the below example picture.

#SPO Sample

$cred = Get-Credential -UserName '@.onmicrosoft.com' -Message "Enter SPO credentials"

#Connect to SPO

Connect-SPOService -Url 'https://-admin.sharepoint.com' -Credential $cred

#Createlist

New-SPOList -Title "Demo list" -Template GenericList -Url 'lists/demo'



Post a Comment

0 Comments