How to modify a help file (*.chm)?
Asked Answered
C

1

5

I generated a help file (*.chm) using HTML Help Workshop.

But there is one line I need to change every time I compile my solution.

Imagine you do have a complete finished *.chm file, but if a server builds the version new, this build number won't get updated in the *.chm file. For now I always deleted this *.chm file and created it new afterwards. Now I reached at a point where it annoys me every time I have to create it new only because the server makes a build. It would be comfortable if i could modify the existing *.chm file directly in my C#-Code.

Is there any possibility to modify a *.chm file with C# code?

Cusped answered 24/9, 2018 at 13:16 Comment(8)
Maybe it's easier to modify a source *.html file and then rebuild the help system.Pentosan
Is this not something you could do with the hhp file or command line args?Geodetic
Edit your question and add some information about one line I need to change every time. Is this really one line in many HTML files? I use FAR HTML for such tasks.Footlocker
@help-info.de: No it isn't. There is ONE line in ONE file which needs to be changed each time the solution gets compiled. I firstly thought of dynamic content, but I think that's impossible to put dynamic values into a *.chm file, isn't it?Cusped
@Sayse: I don't know exactly, I'm totally new to this topic.Cusped
Your question already has close votes. Edit your question and add some information about the file you get stuck. Is this a Problem inside the *.hhp project file?Footlocker
@Footlocker Thanks, you can see the updated question above.Cusped
Why are you putting build numbers into the help file at all? The help file should contain only major and minor version numbers; the documentation shouldn't be changing based on individual builds. When the code has changed enough for the documentation to need to be updated, then the documentation should be edited to include those changes and rebuilt.Preternatural
S
7

Yes. .chm files are really just an archive of a bunch of HTML files and some other bits to hold it all together.

Download a universal zip/unzip program like 7-zip and you can right-click (in windows) your .chm, then choose 7-zip>>Open Archive and you'll see the contents.

Be careful about monkeying around too much in here though since broken links and changed file names will ruin your .chm.

I would agree though that modifying your source before running it up through html-help-workshop is a better option than monkeying with it afterwards.

Swede answered 24/9, 2018 at 13:21 Comment(1)
Note that not every CHM project contains all input files. Specially the hhp often needs to be reconstructed.Planimetry

© 2022 - 2024 — McMap. All rights reserved.