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)