Sandcastle Import Issue

Discussions about Help+Manual 9

Moderators: Alexander Halser, Tim Green

Post Reply
kendoglasgow
Posts: 1
Joined: Fri Jan 05, 2024 10:17 am

Sandcastle Import Issue

Unread post by kendoglasgow »

Hi,

I'm trying to generate code documentation from a C# project using Sandcastle but I'm getting an exception. Log is posted at the end of the message.

The project is DotNet 6.0. I had various issues resolving the references to the various dependencies which I was able to resolve by publishing a platform independent build but I'm stuck with this error.

Please can you advise what I'm doing wrong or recommend a working solution to build documentation from dotnet.

Best regards,
Kenny


Log follows:

Prepare build process ...

Extract help&manual presentation files ...
Version of MrefBuilder.exe: 2.7.2.0

Copy Assemblies and Documentation files ...

Call Microsoft Reference Builder ...
MRefBuilder (v2.7.2.0)
Copyright ¸ 2006-2012, Microsoft Corporation, All Rights Reserved
Info: Loaded 1 assemblies for reflection and 326 dependency assemblies.
Unhandled Exception: System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at System.Compiler.Metadata.MemoryCursor.ReadUTF8(Int32 bytesToRead)
at System.Compiler.Metadata.Reader.GetCustomAttributeLiteralValue(MemoryCursor sigReader, TypeNode& type)
at System.Compiler.Metadata.Reader.GetCustomAttribute(Method cons, MemoryCursor sigReader, Int32 blobLength)
at System.Compiler.Metadata.Reader.GetCustomAttribute(Int32 i)
at System.Compiler.Metadata.Reader.GetCustomAttributesFor(Int32 parentIndex)
at System.Compiler.Metadata.Reader.GetTypeAttributes(TypeNode type, Object handle)
at System.Compiler.TypeNode.get_Attributes()
at Microsoft.Ddue.Tools.Reflection.ExternalDocumentedFilter.IsExposedType(TypeNode type)
at Microsoft.Ddue.Tools.Reflection.ApiFilter.IsExposedAttribute(AttributeNode attribute)
at Microsoft.Ddue.Tools.ManagedReflectionWriter.GetExposedAttributes(AttributeList attributes, SecurityAttributeList securityAttributes)
at Microsoft.Ddue.Tools.ManagedReflectionWriter.WriteAttributes(AttributeList attributes, SecurityAttributeList securityAttributes)
at Microsoft.Ddue.Tools.ManagedReflectionWriter.WriteTypeElements(TypeNode type)
at Microsoft.Ddue.Tools.ManagedReflectionWriter.WriteType(TypeNode type)
at Microsoft.Ddue.Tools.ManagedReflectionWriter.VisitType(TypeNode type)
at Microsoft.Ddue.Tools.Reflection.ApiVisitor.VisitTypes(TypeNodeList types)
at Microsoft.Ddue.Tools.Reflection.ApiVisitor.VisitNamespaces(NamespaceList spaces)
at Microsoft.Ddue.Tools.ManagedReflectionWriter.VisitNamespaces(NamespaceList spaces)
at Microsoft.Ddue.Tools.Reflection.ApiVisitor.VisitApis()
at Microsoft.Ddue.Tools.MRefBuilder.Main(String[] args)
User avatar
Tim Green
Site Admin
Posts: 23189
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Sandcastle Import Issue

Unread post by Tim Green »

Hi Ken,

It would probably be helpful if you could narrow it down to discover which assembly or comments section is triggering the exception. I would do this by adding one at a time and regenerating until I get the error. It's also important to understand that Sandcastle is old -- Microsoft hasn't touched it for several years now, and so it's possible that it's usefulness for current versions of VS may be coming to an end... :?
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
Post Reply