Generate a MadCap Flare TOC from Excel using VBA

When you are crafting a content specification table of contents, you might want to first  “brainstorm” a TOC using Excel, and then simply export the structure to Flare once you’re done. You can write a short VBA function that does the trick. The animated GIF shows how it works and here’s a spreadsheet for you to play with. 🙂

For more info about content specifications, see Kai Weber’s excellent post about it. 

To get the generated TOC to Flare, you need to create a  text file, paste the result from the generateTOC_XML() function, and save the text file with the .fltoc file extension in the Projects > TOC folder in your Flare project.

Image

Here’s the VBA code:

Image

Have fun! 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *