6 Replies Latest reply on Apr 15, 2008 11:53 AM by r0ckness

    Using bookmarks for CSH

      Here's the situation: I'm using RoboHelp7 to create a FlashHelp Pro project. I'm then calling the help from a webpage using the RH_ShowHelp() JavaScript function in RoboHelp_CSH.js. Everything works fine EXCEPT when using an ID linked to a bookmark in a topic. Basically it only pulls up the topic, but doesn't go down to the bookmark within the topic.

      This is a complete guess, but I suspect it may have something to do with the URL being passed to the browser window, as it ends up being something like this: http://server/project.htm#topic.htm#bookmark. If I manually edit the URL to be http://server/topic.htm#bookmark the page displays the way I want it to..... so how do I get it to work with CSH?

      Any help is much appreciated... thanks!
        • 1. Re: Using bookmarks for CSH
          r0ckness Level 1
          • 2. Re: Using bookmarks for CSH
            Level 2
            I'm not real familiar with RH_ShowHelp() for WebHelp as I work almost exclusively with compiled help. I do know that bookmarks don't work in compiled help if you shortcut around the .ali file (using the map number in the .hh file - e.g. #define topicname.htm#bookmark map number - instead of a mapID), generating exactly what you describe.

            What is the syntax of your showHelp call? What do your .hh and .ali files look like?

            • 3. Re: Using bookmarks for CSH
              r0ckness Level 1
              Thanks for the help! You could be right, it might not even be possible to use context sensitive help to call a bookmark. However, I assumed it was since RoboHelp allows you to link a Map ID to a bookmark. In any case, information on the RH_ShowHelp() function is here.

              I'm calling the function using the following parameters: RH_ShowHelp(0, 'http://server/project.htm>Window', HH_HELP_CONTEXT, 29). Map ID #29 is assigned to a bookmark in a topic, similar to this: topic.htm#bookmark.

              I'm not familiar with .ali or .hh files, but here goes.... The .ali file basically lists each topic with its corresponding HTM file. I don't have a .hh file, however the .h file lists a #define for each mapped HTM file. One thing I noticed in the .h file is it looks like the # sign for the bookmark has been replaced with an underscore. So where it was topic#bookmark, it's now topic_bookmark. Not sure if that's significant....

              Thanks again for you help!
              • 4. Re: Using bookmarks for CSH
                MergeThis Level 4
                You and the developer need to coordinate this issue: is the bookmark to be flagged with an underscore or a pound sign? The developer's call and your pathnames must agree, or must be aliased (.ali file).

                An alternative is for the app to simply call the URL, without using the CSH API at all. That's what our C# app and WebHelp use. The developers assume all calls go through index.htm (to get the nav pane frameset; then they look for MainUserWindowFrm.htm if F1 is pressed in the MainUserWindowFrm window. Actually, they first look to field-level help, which we use only for certain windows, then to window-level, then bring up the home page if no window match is found. Because we use merged WebHelp, we also provide a text file in the output root that provides the folder name for each window topic ( ex: form_path.txt, with this format: MainUserWindowFrm, mergedProjects\menus).

                Good luck,
                • 5. Re: Using bookmarks for CSH
                  Level 2
                  Your ShowHelp lists the "project.htm" file, which seems to be the problem in the call that you fixed manually. Using HH_HELP_CONTEXT and a map number should work with the .ali and .h files you have. I would change the RH_ShowHelp call to get rid of the extraneous "project.htm" file.

                  • 6. Re: Using bookmarks for CSH
                    r0ckness Level 1
                    Thanks, I'll give that a try. After closer inspection of the alias file, it looks correct to me... each reference to a bookmarked topic (topic_bookmark) in the .h file has the appropriate alias (topic.htm#bookmark). Thanks again, guys, for your help. I'll let you know what I find out.