HHC5003 error with newest Sandcastle + SHFB

Jul 7, 2010 at 3:10 PM
Edited Jul 7, 2010 at 3:32 PM
I'm trying out the newest Sandcastle and SHFB.  However, when generating the CHM for my project, I'm seeing this error:
<buildStep step="CompilingHelpFile">
Compiling HTML Help 1 file...
[C:\Windows\Microsoft.NET\Framework\v3.5\MSBuild.exe]
Build1xHelpFile:
  Microsoft HTML Help Compiler 4.74.8702
  
  
  
  Compiling D:\MyRoot\bin\v3.5\Release\Working\Output\HtmlHelp1\MyProject.chm
  
  
  
HHC5003 : error : Compilation failed while compiling 459D4F4D.
  
  
  
  
  
  The following files were not compiled:
  
  459D4F4D
  
    Last step completed in 00:00:05.0395
</buildStep>
<buildStep step="Failed">
SHFB: Error BE0043: Unexpected error detected in last build step.  See output above for details.
</buildStep>

The 459D4F4D file is the namespace list and has these contents (anonymized, linebreaks added):

<html xmlns:MSHelp="http://msdn.microsoft.com/mshelp">
<head><title>Namespaces</title><link rel="stylesheet" type="text/css" href="../styles/presentation.css" />
<link rel="stylesheet" type="text/css" href="ms-help://Hx/HxRuntime/HxLink.css" />
<script type="text/javascript" src="../scripts/script_prototype.js"> </script>
<script type="text/javascript" src="../scripts/EventUtilities.js"> </script>
<script type="text/javascript" src="../scripts/StyleUtilities.js"> </script>
<script type="text/javascript" src="../scripts/SplitScreen.js"> </script>
<script type="text/javascript" src="../scripts/ElementCollection.js"> </script>
<script type="text/javascript" src="../scripts/MemberFilter.js"> </script>
<script type="text/javascript" src="../scripts/CollapsibleSection.js"> </script>
<script type="text/javascript" src="../scripts/LanguageFilter.js"> </script>
<script type="text/javascript" src="../scripts/CookieDataStore.js"> </script>
<meta name="file" content="459D4F4D" /><xml xmlns:msxsl="urn:schemas-microsoft-com:xslt">
<MSHelp:Attr Name="AssetID" Value="R:Project" /><MSHelp:Keyword Index="A" Term="R:Project" />
<MSHelp:Attr Name="TopicType" Value="apiref" /><MSHelp:Attr Name="TopicType" Value="kbSyntax" />
<MSHelp:Attr Name="Locale" Value="en-us" /></xml></head><body><div id="control">
<span class="productTitle">MyProject</span><br /><span class="topicTitle">Namespaces</span>
<br /><div id="toolbar"><span id="chickenFeet"><span class="selflink">Namespaces</span></span><span id="languageFilter">
<select id="languageSelector" onchange="var names = this.value.split(' '); toggleVisibleLanguage(names[1]); lfc.switchLanguage(names[0]); store.set('lang',this.value); store.save();">
<option value="CSharp cs">C#</option><option value="VisualBasic vb">Visual Basic</option>
<option value="ManagedCPlusPlus cpp">Visual C++</option></select></span></div></div>
<div id="main"><span style="color: DarkGray"></span><div class="section">
<div class="sectionTitle" onclick="toggleSection(this.parentNode)">
<img src="../icons/collapse_all.gif" /> Namespaces</div><div class="sectionContent">
<table class="members" id="memberList"><tr><th class="nameColumn">Namespace</th>
<th class="descriptionColumn">Description</th></tr><tr><td><b>
<a href="C0F8533A.htm">MyNamespace</a></b></td><td><div class="summary"> </div><br /></td></tr>
<tr><td><b><a href="EA5AFB4A.htm">MyNamespace2</a></b></td><td>
<div class="summary"> </div><br /></td></tr><tr><td><b><a href="BD4C5842.htm">MyNamespace3</a></b></td>
<td><div class="summary"> </div><br /></td></tr><tr><td><b><a href="7E8F4AD5.htm">MyNamespace4</a></b></td>
<td><div class="summary"> </div><br /></td></tr><tr><td><b><a href="AFE6231A.htm">MyNamespace5</a></b></td>
<td><div class="summary"> </div><br /></td></tr><tr><td><b><a href="40A95466.htm">MyNamespace6</a></b></td>
<td><div class="summary"> </div><br /></td></tr></table></div></div><div id="footer"><p />Send comments on this topic to

        <a id="HT_MailLink" href="mailto:myemail@example.com?Subject=MyProject">MyProject Discussion</a><script type="text/javascript">
        var HT_mailLink = document.getElementById("HT_MailLink");
        var HT_mailLinkText = HT_mailLink.innerHTML;
        HT_mailLink.href += ": " + document.title;
        HT_mailLink.innerHTML = HT_mailLinkText;
        </script><p /><a href="http://example.com/" target="_blank">Copyright © 2010</a></div></div></body></html>
Coordinator
Jul 7, 2010 at 3:35 PM

There appears to be a problem with NamingMethod settings other than GUID.  Set the NamingMethod property to GUID for the time being and it should build fine.

Eric

 

Jul 7, 2010 at 4:16 PM

Thanks for the reply.  I tried changing to Guid but I have the same problem with the equivalent file.  "HHC5003 : error : Compilation failed while compiling d4648875-d41a-783b-d5f4-638df39ee413."

Jul 7, 2010 at 5:11 PM

I have the same problem and my NamingMethod was already set to GUID so I get the second error (with the same GUID because its the Namespace page).

The page loads OK in IE8 and all the hyperlinks work, although that probably does not mean anything.

Trevor

 

Coordinator
Jul 7, 2010 at 7:05 PM

I've found and fixed a couple of issues (it isn't setting the default topic ID correctly when there is no conceptual content and using a NamingMethod other than GUID fails).  I'll issue an update this evening to correct the problems.

Eric

 

Jul 7, 2010 at 8:02 PM
Edited Jul 7, 2010 at 8:03 PM

Eric:

I'm also getting the HHC 5003 error. The error indicates it couldn't build the first htm file. When I first open the CHM file, the "Page not found" message is displayed in the right pane of the CHM file. However, if I click on another item in the TOC and then click back to the page where the error first displayed - the page now displays correctly. Here's the message ('XXX' is my substitution to protect privacy of the namespace of the DLL):

HHC5003 : error : Compilation failed while compiling html\N:XXX.XXXX.Common.Data.htm.

The following files were not compiled: 

html\N:XXX.XXXX.Common.Data.htm

 Last step completed in 00:00:05.5313

-------------------------------

SHFB: Error BE0043: Unexpected error detected in last build step. See output above for details.

Coordinator
Jul 7, 2010 at 9:41 PM

It's related to the issues noted above in the reply just before your message.  I've got a fix and will be issuing an update this evening that corrects the problems.

Eric

 

Jul 7, 2010 at 10:01 PM

You rock Eric!

Jul 8, 2010 at 5:33 AM

I've just tried the update and the error has gone away. Thanks Eric!

 

Jul 8, 2010 at 3:06 PM

The error has gone away for me as well.  Thanks a lot for the quick turnaround!