Forum Discussion
María José Pedreira
May 29, 2017Brass Contributor
Allow or avoid items from lists appear in search results with New-PnPList
I have created a Picture Library and I need configure it with value NO for search option.
How do I have to use the search property in the New-PnPLIst command?
New-PnPList -Title "MyImages" -Url "MyImages" -Template "PictureLibrary"
Thank you!
- If you want to do with PnP, below sample might be helpful to you.
$cdx=Get-PnPContext
$group=Get-PnPList -Identity MyImages
$group.NoCrawl =$True
$group.Update()
$cdx.ExecuteQuery()
- If you want to do with PnP, below sample might be helpful to you.
$cdx=Get-PnPContext
$group=Get-PnPList -Identity MyImages
$group.NoCrawl =$True
$group.Update()
$cdx.ExecuteQuery()- María José PedreiraBrass Contributor
NarasimaPerumal Chandramohan Great!
- If New-PnPList does not offer the option to configure this, just use the PnP itself or CSOM to configure that property. Just FYI, you could use the following script as your reference https://gallery.technet.microsoft.com/scriptcenter/How-to-enabledisable-sync-8ad53996?redir=0 and simply change the NoCrawl attribute instead of ExcludeFromOfflineClient