• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Topics opening in new window

Community Beginner ,
Apr 26, 2011 Apr 26, 2011

Copy link to clipboard

Copied

I've run across several posts on how to make a topic open in a new window, but I have the opposite problem. I don't want my topics to open in a new window, but they are.

I have a master project with several child projects merged into it. The Contents tab has a folder called Module Help with subfolders for each of the merged projects. When I expand the TOC for one of the merged projects and click a topic, it displays in the pane to the right as expected. The problem is when I click on a different topic - it opens in a new help viewer window. When I click more topics, they open in this same new window.

I'm using RH X5 to generate .chm files. I'm on Win XP SP3. I didn't set this up, so I'm not familiar with exactly how it all works. The following are sections of code from the master .hhc file that may be useful. If there is something else I can provide, please let me know. Thanks.

From the top of the master project hhc file...

<html>
<!-- Sitemap 1.0 -->
<object type="text/site properties">
  <param name="WindowName" value="Main">
  <param name="SiteType" value="toc">
  <param name="Image Width" value="16">
  <param name="Window Styles" value="0x800402">
  <param name="ExWindow Styles" value="0x100">
</object>
<ul>
  <li><object type="text/sitemap">
    <param name="Name" value="Welcome">
    <param name="Local" value="HelpCenter.chm::/Welcome.htm">
    <param name="WindowName" value="Main">
    <param name="ImageNumber" value="1">
  </object>

  <li><object type="text/sitemap">
    <param name="Name" value="Navigating Through the Software">
    <param name="Local" value="SM.chm::/SMConcepts/navigating_through_the_software.htm">
    <param name="WindowName" value="Main">
    <param name="ImageNumber" value="1">
  </object>

From the section of the master project hhc file with the merged project information for the first two merged projects...

  <li><object type="text/sitemap">
    <param name="Name" value="Module Help">
  </object>
  <object type="text/sitemap">
    <param name="Name" value="Accounts Payable">
    <param name="Merge" value="ap.chm::/ap.hhc">
  </object>
  <object type="text/sitemap">
    <param name="Name" value="Accounts Receivable">
    <param name="Merge" value="ar.chm::/ar.hhc">
  </object>


From of of the merged (child) project's hhc file:

<html>
<!-- Sitemap 1.0 -->
<object type="text/site properties">
  <param name="SiteType" value="toc">
  <param name="Window Styles" value="0x800422">
  <param name="ExWindow Styles" value="0x100">
</object>
<ul>
  <li><object type="text/sitemap">
    <param name="Name" value="Accounts Payable">
  </object>
  <ul>
    <li><object type="text/sitemap">
      <param name="Name" value="Getting Started with Accounts Payable">
    </object>

From the master hhp file:

[OPTIONS]
Compiled File=HelpCenter.chm
Title=HelpCenter
Contents File=HelpCenter.hhc
Index File=HelpCenter.hhk
Default topic=
Default Window=Main
Error log file=
Display compile progress=No
Display compile notes=No
Full-text search=Yes
Binary Index=Yes
Auto Index=No
Enhanced decompilation=No
Binary TOC=No
Flat=No

[WINDOWS]
Main="Help Center","HelpCenter.hhc","HelpCenter.hhk","","","http://www.xxx.com","xxx",,,0x520,0,0x42006,[336,5,1019,711],0x0,0x0,,0,0,0

[FILES]
WebLinks\clientcare.htm

From a child hhp file:

[OPTIONS]
Compiled File=AP.chm
Title=Accounts Payable Help
Contents File=AP.hhc
Index File=AP.hhk
Default topic=
Default Window=main
Error log file=
Display compile progress=No
Display compile notes=No
Full-text search=Yes
Binary Index=Yes
Auto Index=No
Enhanced decompilation=No
Binary TOC=No
Flat=No

[WINDOWS]
main="Help Center","HelpCenter.hhc","AP.hhk","","","http://www.xxx.com","xxx",,,0x520,0,0x42006,[483,5,1022,711],0x0,0x0,,1,0,0

[FILES]
APProcedures\Set_Up_a_1099_Form.htm


Also the hhc files for the master and the merged projects have a [MERGE FILES] section with a list of all merge files.

Views

2.3K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 27, 2011 Apr 27, 2011

Copy link to clipboard

Copied

Hi Ashley.

It is very easy to have just one project project with slightly different SSL settings which can result in this type of thing. go through your projects one by one checking that the Microsoft HTML Help single source layout settings are the same. Pay particular attention to the window being used. Also click the Edit Advanced Settings button to set the correct window there in the Index and TOC Styles tabs.

It would also be worth ensuring that your window properties are the same between projects. Have you a prefix of $global_ for your window names? If not, I suggest you add this as this prefix sorts out all sorts of issues with merged CHMs.


  The RoboColum(n)   @robocolumn   Colum McAndrew

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Apr 28, 2011 Apr 28, 2011

Copy link to clipboard

Copied

Hi Colum,

Thanks for the reply. I changed the default window to $global_main for the master project and I went through and started making this change in all of the merged projects. I also reimported the master project .hhc file into the merged project's baggage files.

The problem with the topics opening in a new window is now fixed, but I was getting this message when I clicked a help topic:

The window name "Main" passed to HH_GET_WIN_TYPE has not been specified. After I clicked OK, the topic would appear.

I double-checked that I had $global_main everywhere it should be, but that didn't help. So I went through and changed the name back to main in the master project and I've started doing it in the merged projects. I thought this had fixed the problem, but now, of course, there is a new one.

When I open the master project .chm file, the TOC appears to be correct, but when I click a topic, it doesn't open. (No messages appear.)

When I open a merged project .chm file, I can click the topics and they appear as expected. However, when I close the .chm file, the following message appears:

hh.exe - Application Error

The instruction at "0x7c919af" referenced memory at "0x0000010". the memory could not be "written".

I've been trying to fix issues related to this TOC for several days now, and I'm at the end of my rope. Any further advice would be greatly appreciated.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 03, 2011 May 03, 2011

Copy link to clipboard

Copied

Hi Ashley.

Sorry for the late response. We have too many bank holidays over here thanks to the royal family 🙂

Regarding the HH_GET_WIN_TYPE error, check out this link: http://kb2.adobe.com/cps/115/rb_11556.html. If this is not relevant check that the help call follows the syntax below:

HH_WINTYPE* pWinType ;
HtmlHelp(
GetDesktopWindow(),
\"Help.chm>mainwin\",
HH_GET_WIN_TYPE,
(DWORD) &pWinType) ;


  The RoboColum(n)   @robocolumn   Colum McAndrew

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
May 03, 2011 May 03, 2011

Copy link to clipboard

Copied

Thanks, Colum. I ended up copying an archived version of the master project and making the required changes, which resolved the issue. I just wish I'd done that on Monday instead of Friday.

Hope you enjoyed the holiday!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
May 01, 2012 May 01, 2012

Copy link to clipboard

Copied

Ashley, We had this problem, and there was one offending child chm file that messed up the whole thing. The problem was an obsecure "Window" setting when you right-click and select Properties on a topic in the TOC, the <Default> setting in the field was blank. For most of our features we have multiple SSLs in a single project for different products. In some cases we want to use a different Window name; creating this second window I think caused a bug that removed <Default> from the the properties field on a single topic, creating the problem. To find the problem I did the following:

  1. Removed one merged file at a time, compiling after each iteration and checking the parent until the problem stopped.
  2. Once it works, you no the last merged file you removed was the problem.
  3. Open the project for the offending child chm, and check the topic properties by right clicking on them in the TOC pane. If you find a properties field blank, select <Default> from the drop-down and this should fix your problem.

Jim

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Jul 09, 2013 Jul 09, 2013

Copy link to clipboard

Copied

LATEST

Using RoboHelp 9, I have recently had the same problems. When opening the master CHM file:

  • Opening one of the merged child project's topics made a new window appear.
  • The child's TOC appeared correctly, but all its index entries were missing from the Index tab (and yes, binary index was correctly selected).

After trying all the other suggestions (which introduced some extra problems) I did this:

  • Delete the child project's window definition(s) and all references to it/them. Just leave everything at <Default>.
  • Save the project and close.
  • Delete the .cpd file.
  • Use a tool like NotePad++ to search all files within the child project folder for stray files still containing references to the window definition. For example, I found RoboHelp had 'forgotten' to remove the window definition name from one line in "Microsoft HTML Help.ssl":

    <element name="m_strTocWindow" value="CustomWindow" />

    ... which I simply replaced with:

    <element name="m_strTocWindow" value="" />
  • Reopen the project and build.

All of the seemingly unconnected index/window problems disappeared. It seems like the child's window definition was conflicting with the master's, and since this child CHM is always viewed from the master, the child has no need for a window definition anyway; it just inherits the master's definition.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
RoboHelp Documentation
Download Adobe RoboHelp