0

I have SharePoint 2016 error with edit any details page take any Page Layout and create new any SP pages also. And I checked the log and I got this error message

Can you help ?

System.ArgumentException: Value does not fall within the expected range.
at Microsoft.SharePoint.Publishing.Fields.ContentTypeIdFieldType.GetFieldValue(String value) 
at Microsoft.SharePoint.SPListItem.ValueFromSafeArrayObject(Object obj, SPField fld) 
at Microsoft.SharePoint.SPListItem.GetValue(SPField fld, Int32 columnNumber, Boolean bRaw, Boolean bThrowException) 
at Microsoft.SharePoint.SPListItem.get_Item(Guid fieldId) 
at Microsoft.SharePoint.Publishing.PageLayout.get_AssociatedContentTypeId() 
at Microsoft.SharePoint.Publishing.PageLayout.get_AssociatedContentType() 
at Microsoft.SharePoint.Publishing.PageLayout.get_UIDisplayName() 
at Microsoft.SharePoint.Publishing.PageLayoutComparerByUIDisplayName.Compare(PageLayout x, PageLayout y) 
at System.Collections.Generic.ArraySortHelper`1.DepthLimitedQuickSort(T[] keys, Int32 left, Int32 right, IComparer`1 comparer, Int32 depthLimit) 
at System.Collections.Generic.ArraySortHelper`1.Sort(T[] keys, Int32 index, Int32 length, IComparer`1 comparer)
6
  • can you run PSconfig if finished successfully? Commented Feb 27, 2019 at 8:51
  • Yes I tried the PSconfig and it's successfully. But the error still exist Commented Feb 27, 2019 at 10:00
  • have you tried create new site collection and edit the page here if the problem is global or only on one site? Commented Feb 27, 2019 at 14:46
  • I think the problem in the site. So I will create new site collection and if the problem still exist I will get back to you . Commented Feb 27, 2019 at 15:11
  • 1
    if its only on the site, try to reactivate Publishing features with PowerShell and -force parameter Commented Feb 27, 2019 at 15:15

1 Answer 1

1

If the issue does not exist on other site collections, then check your custom page layouts, try to remove custom page layouts, and test again

2
  • I tried to create new site collection and once deploy a solution the error still exist. So I will try to remove all custom page layouts and try again .. Commented Feb 28, 2019 at 7:50
  • Yes you are right man, I checked all custom page layouts and I found the problem and resolved that... thanks man :) Commented Feb 28, 2019 at 8:55

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.