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

RoboHelp 2022: Prevent TOC books from opening automatically

Explorer ,
Sep 25, 2025 Sep 25, 2025

Hello.  Is there a way to prevent TOC books from opening automatically when you open a topic in a Responsive HTML5 output?

 

We have topics that are located in multiple books in the TOC.  In previous versions of RoboHelp, if you opened a topic from another topic, it did not change where you were in the TOC.   With the 2022 output, it takes you to the first book in the TOC where this topic is located.  We have our books organized by teams, so that isn't always appropriate.

 

For example, topic A is located in the TOC under the Team 1 book and the Team 2 book.  You're in team 2 and you've opened topic B from the Team 2 book.  Topic B has a link to Topic A, you click on it, and the TOC opens to the location of Topic A in the Team 1 book.  This is confusing and frustrating for team B.


Is there a way to prevent it from doing this and have the TOC books not change at all when you click on one topic from another, similar to how it used to work in RoboHelp 2017?

 

thanks!

Chris

145
Translate
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 Expert ,
Sep 25, 2025 Sep 25, 2025

I think you avoid that by using Snippets that hold the content that appears in separate topics as containers for the snippet. In your example, the content of topic A is in a snippet; the Team 1 book has an empty topic A that holds the snippet A content, and the Team 2 book has an container topic (topic A) that also has the snippet A content. Links to the respective Team topics point to the respective containers.

Translate
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
Explorer ,
Sep 25, 2025 Sep 25, 2025

I can't even imagine how long it would take to do that across the entire projects.  There are so many topics that are shared.  And then if the title changes for that content, now it has to be changed in each of the empty topics as well? Rather than just being changed once and automatically updated in the TOC.  And it would increase the number of topics by a lot; maybe even double it because some topics are shared by 3, 4, or 5 teams.

 

If we could just prevent the TOC from changing at all, that would be so much better.  And it would be nice even in cases where other teams weren't involved.  Users often have a book open and want to stay there, which is how it used to work.

 

I suppose we could change the links to open in a new window instead, but there are cases where we really don't want to do that.

Translate
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 Expert ,
Sep 25, 2025 Sep 25, 2025

"And then if the title changes for that content, now it has to be changed in each of the empty topics as well?" - no, of course not, that's the whole point of snippets - you edit the snippet & the changes appear everywhere that snippet is used. 

Translate
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
Explorer ,
Sep 25, 2025 Sep 25, 2025

But the title of the snippet is not what's going to appear in the TOC; the TOC will show the title of the empty topic that houses the snippet.   Won't it?  If I have 3 different empty topics in 3 different books, all with the same snippet, and the title of the content changes, then I have to change it in the snippet and in each empty topic.  Otherwise if I only change it in the snippet, the TOC will still show the old name and then when you click on it, you'll see the new name.  

Translate
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 Expert ,
Sep 26, 2025 Sep 26, 2025

Yes each topic will have a title and that would have to change. One alternative is what you have, one topic in multiple places but that has issues.

 

Another option is one topic with the content and then other topics that have a redirect. When opened they will open the topic that has the content.

________________________________________________________

My site www.grainge.org includes many free Authoring and RoboHelp resources that may be of help.

 

Help others by clicking Correct Answer if the question is answered. Found the answer elsewhere? Share it here. "Upvote" is for useful posts.
Translate
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 Expert ,
Sep 26, 2025 Sep 26, 2025

I usually put the title of the topic at the top of the container topic and then add the snippet after it. That way I can make the TOC either read the same in each location of change it to match whatever is going on in that part of the TOC. In one of my projects I produce 2 flavours of help that have about 95% the same content. In one flavour, one of the modules' programs (and thus their help topics) are located right off the main menu in another, tucked in as a sub-module to another. I use the container approach and conditional tags to make them appear or not in each flavour produced.  

Translate
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 Expert ,
Sep 26, 2025 Sep 26, 2025

I think what @Christine301653386cjz is getting at is the Topic Title as in Properties rather than the Topic Heading as in the topic itself. By default when you create a topic they are the same but thereafter, they may not be.

 

There is a downside to my redirect suggestion. I think that will open the TOC at the book with the topic containing the content rather than the topic with the redirect. It needs some testing.

 

I suspect the answer will be each method has pros and cons. Which is the best on balance?

________________________________________________________

My site www.grainge.org includes many free Authoring and RoboHelp resources that may be of help.

 

Help others by clicking Correct Answer if the question is answered. Found the answer elsewhere? Share it here. "Upvote" is for useful posts.
Translate
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
Explorer ,
Sep 29, 2025 Sep 29, 2025

Thank you for these ideas!  I tried using a redirect topic, and it just opens the first book in the project.  However, it did lead me to compare the code between the topics, and I found that if I change this:

<meta name="gTopicId" content="5.4.0_2"/> (or whatever the individual toc location is)

to this:

<meta name="gTopicId" content="0"/>

 

It works exactly how we want it to work - it doesn't open any TOC books and will work the way the 2017 (and prior) versions did.  The user goes to the folder that they want, and they stay there until they choose to go to another one.  The drawback is I'd have to change that code in all of the topics initially, and then everytime I update a topic I'd have to change it after generating because it'll revert back, but that's still much less maintenance than having so many more topics to maintain.  

 

I don't suppose you would know of a file I could go into that would just make the topic ID "0" for all topics?

Translate
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
Explorer ,
Oct 10, 2025 Oct 10, 2025

During this process I noticed something that might be helpful to others if they come across this too.  RoboHelp 2022 adds the TOC location to every topic in the output (for example, <meta name="gTopicId" content="5.4.0_2"/>).  If you add or remove a topic from the TOC, or rename a topic and it causes the other topics to shift in the TOC, the other topics that were below the changed one in the TOC have that topic location changed in the output.  For example the topic at 5.4.0_2 might now be 5.4.0_3, and the one that ended with 3 is now 4, etc.

 

We do not upload the entire output to our live site every time something changes in the project - only the topics that were changed and the TOC and search files if needed.  As a result, the TOC would now point to the wrong topic for files that weren't uploaded, because those topics still had the old TOC location.

 

So if you are using RH2022 as it was intended with the TOC opening automatically as described in the OP, I guess you have to upload either the entire output or at least all of the topics located in the TOC book that changed.  I wouldn't want to do that because I might be in the process of editing a topic and not ready for it to be updated in our live site, and we also reverify every topic that is uploaded just to make sure everything is correct and nothing odd happened.

 

So this is another reason why it would be very nice to be able to disable the TOC behavior described in the OP and have the TOC not change automatically.  In the meantime, I've changed that meta code to <meta name="gTopicId" content="0"/> in every topic on our live site.  When a  topic is updated, and I upload it from the output to the live site, I just have to go in and make that same change again.  It is pretty fast to do in Notepad and even though it's more maintenance than I'd like, it's less maintenance than creating multiple container topics - I think that would be a better solution for if we had less shared topics, and it might still work really well for others. 

 

If anyone who is much more tech savvy than I am knows if there is something  I can do behind the scenes in one of the RoboHelp program files that would make each topic get the <meta name="gTopicId" content="0"/> code in the output (instead of the different toc locations), that would be great.  But if not this works well enough for now.

 

Thanks again Peter for the suggestion, even if I didn't use it, because it helped me to find what I was looking for.; I had been looking for TOC or table of contents in the code and don't think I would have noticed the gTopicID if I hadn't created the redirect topic and then compared them to find out what made the TOC open to the first book (those had an ID of 1 and it gave me the idea to change it to 0).

Translate
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 Expert ,
Oct 10, 2025 Oct 10, 2025

I take it that you're not using the Publishing function - that would handle your objective of only uploading files that changed to the server site. With just Generating, you're performing the uploading portion of the workflow manually. In that case, the recommended action is to clear the target location on the server and upload all the output files again each time. 

Translate
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
Explorer ,
Oct 10, 2025 Oct 10, 2025

That's correct.  Somewhat related/unrelated question - does the status of a topic affect the publishing?  I'm pretty sure that the status was informational only in RH2017, and haven't found anything yet showing otherwise for 2022. 

 

I definitely wouldn't want to use the publish feature now with the TOC solution in place, but I'm curious for other projects in the future.  If I have a topic that is live but I'm editing it in RoboHep and not ready to publish it yet - would setting the status to draft or in progress do anything to prevent it from replacing the current live version, either when generating or publishing?

Translate
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 Expert ,
Oct 10, 2025 Oct 10, 2025

Status does not affect whether or not a topic is generated. Use Condition Tags and Expressions for that.

________________________________________________________

My site www.grainge.org includes many free Authoring and RoboHelp resources that may be of help.

  

Help others by clicking Correct Answer if the question is answered. Found the answer elsewhere? Share it here. "Upvote" is for useful posts.
Translate
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
Explorer ,
Oct 10, 2025 Oct 10, 2025
LATEST

I think it would also remove it from the TOC then in that case?  Or at least for the conditional build tag; I think I'd have to look into expressions.  I think there's probably no way of doing what I'd want - which is to edit a topic in RH but leave it completely alone on our live site - if I used the publish method.  I guess I could publish and then restore the old version, or copy the old version somewhere else and then copy it back to the live site. 

Translate
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 Expert ,
Oct 10, 2025 Oct 10, 2025

No, you'd need a version control system to achieve that - if you're editing a topic and then generating help with that topic included (assuming you haven't used conditional build tags or excluded it from the TOC) then your changes are going to end up in the output. A version control system prevents that from happening; while you've got a topic checked out for editing, the original topic still resides in the repo and any output generated would use that content, not the changed topic you still have checked out.

Translate
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 Expert ,
Oct 10, 2025 Oct 10, 2025

Also be aware that Search will not be updated the way you are working.

________________________________________________________

My site www.grainge.org includes many free Authoring and RoboHelp resources that may be of help.

  

Help others by clicking Correct Answer if the question is answered. Found the answer elsewhere? Share it here. "Upvote" is for useful posts.
Translate
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
Explorer ,
Oct 10, 2025 Oct 10, 2025

I don't upload it everytime something minor has changed, but I do pretty often just upload the entire contents of the whxdata folder, and I think that takes care of the search too.

Translate
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