I am using SharePoint 2013 Site collection. I am trying to get the Navigation Setting details for each web inside the site collection using PowerShell. Using below lines of code to retrieve the same. But getting incorrect result.

$SPPubWeb = [Microsoft.SharePoint.Publishing.PublishingWeb]::GetPublishingWeb($web) $SPPubWeb.Navigation.InheritGlobal $SPPubWeb.Navigation.InheritCurrent

Both InheritGlobal & InheritCurrent return false whereas if I see the site navigation settings page manually the web is inheriting from it's parent for global and current navigation.

Could you please guide If I am doing something wrong here.

Thanks in advance!

1 Answer 1


I tested with your cmdlet and it works fine. The properties change will reflects in the results I get when I change in navigation settings. Have a try to get the SP web object again and check the properties

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.