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

Script error printing related topics

New Here ,
May 02, 2008 May 02, 2008
I am using X3. The problem appears to be that when more than one topic is being printed, the topics are copied from the store into a single combined temporary file in the temp folder. This combined file contains a reference to ehlpdhtm.js which does not exist in the temp folder so script errors result. When printing single topics there is no problem because they are printed direct from the store which is presumably where ehlpdhtm.js resides. This is such an obvious problem that there must be a simple solution and yet Google cannot find anything.
847
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
LEGEND ,
May 02, 2008 May 02, 2008
Welcome to our community, Peter

Something to consider. If offering printed output, you can avoid the issues by simply providing an alternate that is used for the purposes of printing. For example, a link to a PDF version you supply. Have the user print from the PDF.

There will likely always be a constant struggle when attempting to print what has been designed to display on screen.

Just thinking out loud... Rick
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
Enthusiast ,
May 02, 2008 May 02, 2008
Hi, Peter,

Here's an explanation from Marc Islam of Microsoft of why this problem occurs:
quote:

When printing multiple topics, HTML Help will concatenate all of the topics together into one temporary file, load the file into a new HTML Help process, and issue a command to IE to print the file.

Since the merged file can only have one <HEAD> section, the first topic in the merged file is the one that gets to define which JS and CSS files are used by all of the topics in the merged file.
There's an article in the Microsoft Knowledge Base that suggests a workaround:

http://support.microsoft.com/?kbid=830609

And snippet 46 on Peter Grainge's site may help.

http://www.grainge.org/pages/snippets/snippets.htm

In each case, the suggested workarounds apply as much to script files as they do to style sheets. For example, with the Microsoft solution, you would change your <script> elements to something like this:

<script language="text/javascript" src="ms-its:YourHelpFile.chm::/ehlpdhtm.js"></script>

Pete
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
New Here ,
May 07, 2008 May 07, 2008
LATEST
Thanks for the suggestions. I have read the links and read around them a little as well. It pretty much confirms what I already thought. However, this still leaves me with a fundamental problem. Am I missing something here? I thought this was the RoboHelp for Word forum but it looks to me like you guys are RoboHelp for HTML experts. For example, I have no <script ...> to change, all I have is an RTF file. RoboHelp for Word generates all the html files, compiles them and then deletes them before I can make any changes.
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