Solved

CHM File generated with Robohelp: How do I retain the user size and placement of the help window?

Posted on 2007-11-28
6
1,608 Views
Last Modified: 2012-06-21
I have generated a CHM file using RoboHelp for Word 6 build 099. I am able to open the help file from my C# project and I can open with context sensitivity. My problem is that the help window always opens to the original size. That is,  if the user resizes the help window, closes it, and then reopens the help window, it does not retain the user's resizing information.
Is there a setting in RoboHelp (or elsewhere) that will retain the user's resetting of the help file winow size/placement information?
0
Comment
Question by:cupper
  • 3
  • 2
6 Comments
 

Expert Comment

by:Sephrial
Comment Utility
No, there is no setting in RoboHelp to retain window size placement/size.  For WinHelp projects you can define the window as a percentage of the screen size or with an absolute pixel size.  For HTML Help and other output formats, the placement of the window is determined by the viewer or browser for that file format (clients can use different viewers).  If there is no way for those browsers to pass in the placement and the viewer doesn't retain those settings automatically, you may be out of luck.
0
 

Author Comment

by:cupper
Comment Utility
Is there something that can be done outside of RoboHelp? I've seen postings on other forums related to a file in the documents and settings directory with the name HH.DAT.  It seems like this file stores information related to the coordinates for the help window. I thought maybe there was a way to set this in Robohelp but if not, I would accept a solution that is external to Robohelp. I know I have used CHM files from software distributors that remember the screen settings.
 
0
 

Expert Comment

by:Sephrial
Comment Utility
Hum, actually it looks like you CAN set the persistance of the window size using HHW:

Check out Char James-Tanny's HTML Help Workshop tutorial (Customizing the Window Section):
http://frogleg.mvps.org/helptechnologies/htmlhelp/pdfs/char_hhw.zip
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 7

Accepted Solution

by:
help-info earned 500 total points
Comment Utility
I'm not using RoboHelp and I'm not quite sure but expecting RoboHelp has such options to store the help window's user settings. So I'd recommend to look deep into all options of RoboHelp.

You are right the settings are saved in the hh.dat file. But you cannot edit this file. You can do that by HTMLHelp Workshop *before* compiling your HTMLHelp (CHM) project. . At the window size and definiton here is a option "Save user defined window position after first use". Look for something like this at RoboHelp.
In a *.hhp file you can edit the window default values (decimal) by a plain text editor like Notepad. For the "save position" option you need to add hex values (see: 0x23520 changed to 0x63520)
example1:
[WINDOWS]
main="Online Help","CHM-example.hhc","CHM-example.hhk","index.htm","index.htm",,,,,0x23520,275,0x1046,[317,243,947,683],0xb0000,,,,,,0
example2:
[WINDOWS]
main="Online Help","CHM-example.hhc","CHM-example.hhk","index.htm","index.htm",,,,,0x63520,275,0x1046,[317,243,947,683],0xb0000,,,,,,0

You maybe intested in following link:
http://www.help-info.de/en/xml/maml_faq.xml#htmlhelp

HTH
Best regards
Ulrich Kulle
Microsoft MVP - Windows Help
***********************************
http://www.help-info.de
***********************************
0
 

Expert Comment

by:Sephrial
Comment Utility
In conclusion, your best bet is to compile the CHM file with a default value for the window size/position, and check the apply persistence option.

If you did not have access to change the CHM's properties, or they were overridden by the application, than you would want to call the CHM file viewer from an API and attempt to modify the size of the window using the window handle.  The only problem is the viewer may override this by reading from that DAT file for example.  On the page that help-info provided, you see they have a HTML Help API for C++/MFC and they call the HTMLHelp() constructor and pass in a HWND pointer.  So, you may be able to change the size of the window programatically as well.  I don't know if there is a C# equivalent API for HTMLHelp though.
0
 

Author Closing Comment

by:cupper
Comment Utility
Ulrich,
Thank you. While your answer didn't provide direct information on RoboHelp(I was never able to find a Robohelp equivalent for "Save user defined window position after first use"), I was able to modify the *.hhp file produced by Robohelp as you described. Once that was done, I was able to recompile using HTML Help workshop after I changed the hhp file produced by Robohelp.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Article by: Ivo
Anonymous Types in C# by Ivo Stoykov Anonymous Types are useful when  we do not need to follow usual work-flow -- creating object of some type, assign some read-only values and then doing something with them. Instead we can encapsulate this read…
In order to hide the "ugly" records selectors (triangles) in the rowheaders, here are some suggestions. Microsoft doesn't have a direct method/property to do it. You can only hide the rowheader column. First solution, the easy way The first sol…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now