chmmaker.lpi in the tools directory won't compile lazarus / 31-LCL ---------------------------------------------------------------------- Bert_Plitt · 2022-02-01 19:25 Am I doing anything wrong?  I tried to compile and run chmmaker.lpi which came with Lazarus install.  It produced errors, see the attached figure.  Is this a bug?  I need help to get this to run. ---------------------------------------------------------------------- wp · 2022-02-01 23:29 I think nobody tested this program since May 2019 when the associated changed has been made with the ChmSitemap unit in the FCL chm package... Please report a bug. ---------------------------------------------------------------------- Bert_Plitt · 2022-02-02 00:46 WP -- I'm not fluent in this forum.  How do I report a bug?  Is there an instruction doc somewhere? ---------------------------------------------------------------------- Leledumbo · 2022-02-02 04:25 Quote from: Bert_Plitt on February 02, 2022, 01:46:12 amWP -- I'm not fluent in this forum.  How do I report a bug?  Is there an instruction doc somewhere? https://wiki.lazarus.freepascal.org/How_do_I_create_a_bug_report ---------------------------------------------------------------------- wp · 2022-02-02 17:46 I fixed it. The changes are in Lazarus/main and will be backported to Laz/fixes (--> Laz 2.2.2). If you don't use main/fixes or do not want to wait for v2.2.2 you can fix it easily by yourself: Open file CHMSiteMapEditor.pas in LazarusCompile: The editor will jump to the first error line "ChmItem.URL := TreeNode.URL". Replace this by "ChmItem.AddURL(TreeNode.URL)".Compile again: The next error line is immediately below. Replace "ChmItem.Local := TreeNode.Local" by "ChmItem.AddLocal(TreeNode.Local)"Compile again: The next error line is "TreeNode.ULR := ChmItem.URL". Replace it by "TreeNode.URL := ChmItem.SubItem[0].URL".Compile again - successfulI loaded and compiled the sample help project in the "example" folder. The result was a valid chm file which could be viewed by both LHelp and the Windows chm viewer. ---------------------------------------------------------------------- Bert_Plitt · 2022-02-03 01:22 WP - Thanks for your reply.  I made the changes you listed and as you said, I was able to compile and run the example project and view the generated help file.  But, there is a new problem.  With the example project loaded, I used the speed button to load the "Table Of Contents" file (*.hhc) from the example folder into the TOC edit window.  When I clicked the "Edit" button, I got a SIGSEVG error.  I attached figures showing the error.  It was with one of the new lines you added.  I hope this is fixable. ---------------------------------------------------------------------- wp · 2022-02-03 14:42 Sorry, I should have added a check whether there are any SubItems at all. So please insert a "if ChmItem.SubItemCount > 0 then" before the offending line. Tried to test whether the URL handling by my fix is correct, but I did not find an example in my own chm file projects where this is used (I am not the author of this currently unmaintained tool, and am not doing much more than guessing blindly...). My overall impression of chmmaker, however, is that it is still quite buggy. For example, there is the DelphiMoon package on Online-Package- Manager for which I wrote the help file as a Microsoft HTML Help project. When I do the same with these files in chmmaker the generated chm file does not open the links of the help contents - there still seem to be issues with subdirectories. Only when I copy all files need into the folder of the help project (and adjust the links used in the html, hhc and hh files), the created chm works correctly. I am attaching this modified help project so that you have something to play with. But basically, if today I'd have to create a help project I'd use the Microsoft HTML Help Workshop rather than chmmaker. Or I'd even start with a commercial product such as HelpNDoc for which I have a license (but there is also a free version with minor restrictions). ---------------------------------------------------------------------- Bert_Plitt · 2022-02-03 15:45 WP - I'll add your additional fix and see how I do.  However, based on your additional comments, I think I may abandon trying to use chmmaker.  I already downloaded the free version of HelpNDoc and played with it a little.  I thought chmmker might be quicker to learn and because it is included in Lazarus tools, thought it might be easier to incorporate into the project I'm working on.  Thanks for all your help.  As you probably can tell, I am in no way a programmer!  I'm a retired electronics engineer who fiddles with fpc and Lazarus to keep busy, keep my brain active, and maybe learn something.  You've responded to several of my posts in the past, for which I'm grateful.  And because of your help, I've gotten a little better at using Lazarus.  So now I guess I'll have to learn how to make HTML files for the help project.  Can you recommend a free software that will automatically produce HTML code from plain text written by, say, MS word or it's own text editor? Once again, thanks. ---------------------------------------------------------------------- wp · 2022-02-03 15:55 When your first priority is creating chm files I'd go with HelpNDoc. You can use it like Word/Writer etc, and I think you don't see the html in the background. They have a lot of videos on their website to explain most of it. You can see a typical HelpNDoc project in my rework of the LazStats program (https://sourceforge.net/p/lazarus- ccr/svn/HEAD/tree/applications/lazstats/) - the main work is just adding nodes to the tree and pasting text and screenshots into the editor. On the other hand, when your first priority is learning HTML, I'd simply use a text editor. I'm not an expert in this, but what I've seen as the output of the html editors is awful html code and extremely hard to understand. When you write every line by yourself you see what is happening. An extremely helpful site is for me the tutorial of https://www.w3schools.com/html/default.asp which has "Try it yourself" buttons for every topic so that you get a feedback to your code immediately in the browser. ---------------------------------------------------------------------- marcov · 2022-02-11 12:57 I added some emergency fixes to chmmaker. I suspect there is another "recent" introduced issue wrt the directory where saved files are saved (they are now in chmmaker/ not chmmaker/example). "Recent" in quotes since these changes are probably 3 or 4 years old. Please test.