Defining the size and position of the CHM window in output

When you launch your HTML Help output file (*.chm), you may find that it opens with a size or position that doesn't suit your content. With a simple modification to the HTML Help template file, you can explicitly define the size and location of that CHM window every time it opens on a user's system.

In order to make a change to the HHP template, you'll have to perform a project override. You can find details on this procedure in our TechNotes here: http://webworks.com/technotes/articles/ePublisherPro/EX_ePub_Project_Format_Overrides.36.1.aspx

Follow these steps to override template.hhp:

1. In your project folder (where the *.wep is), create a new folder and name it "Formats".

2. Within the new folder, create another new folder, and name this one "Microsoft HTML Help 1.x" (remember--all folders and file names must use the exact spelling and capitalization as their original versions in the ePublisher Pro directory).

3. Within that folder, create one more new folder, and call it "Pages".

4. Open a new Windows Explorer window, and navigate to this folder in the ePublisher Pro directory: C:\Program Files\WebWorks\ePublisher Pro\Formats\Microsoft HTML Help 1.x\Pages\

5. Copy the template.hhp file (Ctrl + C).

6. Paste it into the "Pages" folder you created in step 3.

7. Open the new copy of template.hhp with a text editor (you should be able to right-click and choose "Edit in Notepad").

8. Find this line in the text file: TriPane=,"$TOCName;","$IndexName;","$DefaultTopic;","$HomePage;",0x35200x3006,,0

9. Following the comma after 0x3006, add this text (include the brackets): [XXX,YYY,AAA,BBB] where: XXX = the window's lefthand position in pixels YYY = the window's top position in pixels AAA = the window's right-side position in pixels (left + width) BBB = the window's bottom position in pixels (top + height)

10. Save template.hhp and regenerate your project to apply the changes.

Next time you launch the generated output CHM, it should open with the specified dimensions.


CategorySolutionsOutputChm

LaurenLever/@Solutions/Output/Microsoft HTML Help 1.x/Size and position of window (last edited 2009-06-02 19:22:15 by LaurenLever)