Got a special project and need to remove content from a CHM, then recompile. Importing and decompiling the CHM was easy as was removing the content. Now hitting a road block with the aliases. After import there were not aliases and map IDs defined. I got the header file from the developer and that imported fine....except that none of the aliases are linked to the topics. Looking at 400 aliases and not very descriptive topic names.
Does anyone have an idea on how to get the alias -> topic links out of the CHM?
Reverse engineering aliases from CHM
-
- Senior Propellus Maximus
- Posts: 4293
- Joined: Thu Feb 02, 2006 9:29 am
- Location: The Electric City
Reverse engineering aliases from CHM
New Book: Creating user-friendly Online Help
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
Re: Reverse engineering aliases from CHM
If I try importing a CHM that was created by Flare, the alias file is blank in the project it creates. So it looks like it doesn't work.
But I can decompile the same CHM using Microsoft HTML Help Workshop (https://www.microsoft.com/en-gb/downloa ... x?id=21138), and the files include the alias file in Data\Alias.xml.
So if you use the alias file from a decompiled project, along with your header file, it should hopefully work.
But I can decompile the same CHM using Microsoft HTML Help Workshop (https://www.microsoft.com/en-gb/downloa ... x?id=21138), and the files include the alias file in Data\Alias.xml.
So if you use the alias file from a decompiled project, along with your header file, it should hopefully work.
-
- Senior Propellus Maximus
- Posts: 4293
- Joined: Thu Feb 02, 2006 9:29 am
- Location: The Electric City
Re: Reverse engineering aliases from CHM
Thanks! I give this a try. Did find KeyTools and using the analyze feature to find the alias map in the CHM, but that means reassigning the topics by hand. It is rather tedious work.
New Book: Creating user-friendly Online Help
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
-
- Senior Propellus Maximus
- Posts: 4293
- Joined: Thu Feb 02, 2006 9:29 am
- Location: The Electric City
Re: Reverse engineering aliases from CHM
Tried it and there is no Data folder created on decompile. So back to the original plan of patching things up manually...it will be a looong looong day.
At least I will have a working Flare project in the end and unlike the old tech writer I will put a copy out on the network and into source control.
At least I will have a working Flare project in the end and unlike the old tech writer I will put a copy out on the network and into source control.
New Book: Creating user-friendly Online Help
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
Re: Reverse engineering aliases from CHM
Ah, maybe your CHM file wasn't originally created by Flare then - mine was, so it had the alias file.
The original HHP file would contain the mappings, but unfortunately HTML Help Workshop doesn't decompile/reconstruct the HHP file.
I've not used KeyTools, but can that not decompile the HHP file?
The original HHP file would contain the mappings, but unfortunately HTML Help Workshop doesn't decompile/reconstruct the HHP file.
I've not used KeyTools, but can that not decompile the HHP file?
-
- Senior Propellus Maximus
- Posts: 4293
- Joined: Thu Feb 02, 2006 9:29 am
- Location: The Electric City
Re: Reverse engineering aliases from CHM
The original CHM was created with WebWorks from a FrameMaker project...and no, I don't have the FM project for importing, which wouldn't have helped me anyway since the mappings were made in WebWorks.
KeyTools shows the ID - topic matches like this:
KeyTools shows the ID - topic matches like this:
With the header file loaded I get the map IDs and aliases. With the info from KeyTools I get the map ID and topic mappings. Ordering the aliases by map ID makes it somewhat easy, but it is still tedious. The rather useless names for the topics are not helping either, neither do the aliases. Aliases and IDs were assigned by the devs, so there is no naming and numbering convention, they just took the last map ID, added 10, and assigned that new ID to the help button in a new form.5521 = VTUG20_Students.03.51.html
5530 = VTUG20_Students.03.53.html
5531 = VTUG20_Students.03.56.html
5540 = VTUG30_Map.05.083.html
New Book: Creating user-friendly Online Help
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
Paperback http://www.amazon.com/dp/1449952038/ or https://www.createspace.com/3416509
eBook http://www.amazon.com/dp/B005XB9E3U
Re: Reverse engineering aliases from CHM
That's not too bad if you can get it in that format as a text file, as the id and filename have a "=" delimiter.RamonS wrote:5521 = VTUG20_Students.03.51.html
5530 = VTUG20_Students.03.53.html
5531 = VTUG20_Students.03.56.html
5540 = VTUG30_Map.05.083.html
You could use this in a text editor (or even Excel), and with a bit of find and replace you could reformat it into Flare's alias XML format; e.g.
Code: Select all
<Map Name="5521" Link="/Content/VTUG20_Students.03.51.html " />