Try our conversational search powered by Generative AI!

Error related to PageTypeBuilder; System.Reflection.CustomAttributeFormatException: 'LongStringSettings' property specified was not found

Vote:
 
I am running a project using EpiServer CMS 6 (EpiServer.CMS.Core.6.1.379.0) and PageTypeBuilder 2.
The server is using .NET Framework 4.

I got an error related to PageTypeBuilder and the assembly-version.
After that I used 'gacutil -i PageTypeBuilder.dll' in order to put the assemble into the Global Assembly Cache. After that I got an error related to the
file Autofac.dll, and I subsequently added that to the same cache.

When browsing the website through Internet Information Services 7 I get the following error:
System.Reflection.CustomAttributeFormatException: 'LongStringSettings' property specified was not found. ---> System.Reflection.CustomAttributeFormatException: 'LongStringSettings' property specified was not found. at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeModule decoratedModule, Int32 decoratedMetadataToken, Int32 pcaCount, RuntimeType attributeFilterType, Boolean mustBeInheritable, IList derivedAttributes, Boolean isDecoratedTargetSecurityTransparent) --- End of inner exception stack trace --- at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeModule decoratedModule, Int32 decoratedMetadataToken, Int32 pcaCount, RuntimeType attributeFilterType, Boolean mustBeInheritable, IList derivedAttributes, Boolean isDecoratedTargetSecurityTransparent) at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimePropertyInfo property, RuntimeType caType) at PageTypeBuilder.Reflection.MethodInfoExtensions.HasAttribute(MemberInfo memberInfo, Type attributeType) at System.Linq.Enumerable.WhereArrayIterator`1.MoveNext() at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection) at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source) at PageTypeBuilder.Synchronization.Validation.PageTypeDefinitionPropertiesValidator.ValidatePageTypeProperties(PageTypeDefinition definition) at PageTypeBuilder.Synchronization.Validation.PageTypeDefinitionValidator.ValidatePageTypeDefinitions(IEnumerable`1 pageTypeDefinitions) at PageTypeBuilder.Synchronization.PageTypeSynchronizer.SynchronizePageTypes() at PageTypeBuilder.Initializer.Initialize(InitializationEngine context) at EPiServer.Framework.Initialization.InitializationEngine.InitializeModules() 2012-09-13 12:16:50,271 WARN [1] EPiServer.Events.Remote.RemoteEventsManager.RegisterHandler - Remote Events are disabled 2012-09-13 12:16:50,276 WARN [1] EPiServer.Events.Remote.RemoteEventsManager.RegisterHandler - Remote Events are disabled 2012-09-13 12:16:50,278 WARN [1] EPiServer.Events.Remote.RemoteEventsManager.RegisterHandler - Remote Events are disabled 2012-09-13 12:16:50,279 WARN [1] EPiServer.Events.Remote.RemoteEventsManager.RegisterHandler - Remote Events are disabled 2012-09-13 12:16:50,291 WARN [1] EPiServer.Events.Remote.RemoteEventsManager.RegisterHandler - Remote Events are disabled 2012-09-13 12:16:50,293 WARN [1] EPiServer.Events.Remote.RemoteEventsManager.RegisterHandler - Remote Events are disabled 2012-09-13 12:17:04,699 ERROR [1] EPiServer.Framework.Initialization.InitializationEngine.InitializeModules - Initialize action failed for Initialize on class PageTypeBuilder.Initializer, PageTypeBuilder, Version=2.0.0.0, Culture=neutral, PublicKeyToken=6fb8762af0e6dbed System.Reflection.CustomAttributeFormatException: 'LongStringSettings' property specified was not found. ---> System.Reflection.CustomAttributeFormatException: 'LongStringSettings' property specified was not found. at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeModule decoratedModule, Int32 decoratedMetadataToken, Int32 pcaCount, RuntimeType attributeFilterType, Boolean mustBeInheritable, IList derivedAttributes, Boolean isDecoratedTargetSecurityTransparent) --- End of inner exception stack trace --- at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeModule decoratedModule, Int32 decoratedMetadataToken, Int32 pcaCount, RuntimeType attributeFilterType, Boolean mustBeInheritable, IList derivedAttributes, Boolean isDecoratedTargetSecurityTransparent) at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimePropertyInfo property, RuntimeType caType) at PageTypeBuilder.Reflection.MethodInfoExtensions.HasAttribute(MemberInfo memberInfo, Type attributeType) at System.Linq.Enumerable.WhereArrayIterator`1.MoveNext() at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection) at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source) at PageTypeBuilder.Synchronization.Validation.PageTypeDefinitionPropertiesValidator.ValidatePageTypeProperties(PageTypeDefinition definition) at PageTypeBuilder.Synchronization.Validation.PageTypeDefinitionValidator.ValidatePageTypeDefinitions(IEnumerable`1 pageTypeDefinitions) at PageTypeBuilder.Synchronization.PageTypeSynchronizer.SynchronizePageTypes() at PageTypeBuilder.Initializer.Initialize(InitializationEngine context) at EPiServer.Framework.Initialization.InitializationEngine.InitializeModules()

How do I solve this?

    Thanks in advance for your help!

Anders Branderud

#61261
Sep 13, 2012 12:48
Vote:
 

I found out that the error was created because a module using an old PageTypeBuilder-version.


Solution - I added this to web.config:

<dependentAssembly>
 <assemblyIdentity name="PageTypeBuilder" publicKeyToken="6fb8762af0e6dbed" culture="neutral" />
 <bindingRedirect oldVersion="1.9.0.0-2.0.0.0" newVersion="2.0.0.0" />
 <bindingRedirect oldVersion="1.0.0.0-1.3.1.0" newVersion="1.3.1.0" />
 <codeBase version="1.3.1.0" href="bin\ptb131\PageTypeBuilder.dll" />
 </dependentAssembly>
    
#61269
Edited, Sep 13, 2012 14:15
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.